https://github.com/libsdl-org/libtiff/commit/0fedb04f8dd2510669589143597d3b6ed38a0fc4
From 0fedb04f8dd2510669589143597d3b6ed38a0fc4 Mon Sep 17 00:00:00 2001
From: Bob Friesenhahn <[EMAIL REDACTED]>
Date: Tue, 8 Jun 2010 19:13:03 +0000
Subject: [PATCH] * libtiff/tif_aux.c (_TIFFCheckRealloc): Produce a fully
detailed error message string.
---
ChangeLog | 3 +++
libtiff/tif_aux.c | 6 ++++--
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 6ce86c0a..6d8747c4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2010-06-08 Bob Friesenhahn <bfriesen@simple.dallas.tx.us>
+ * libtiff/tif_aux.c (_TIFFCheckRealloc): Produce a fully detailed
+ error message string.
+
* Add an emacs formatting mode footer to all source files so that
emacs can be effectively used.
diff --git a/libtiff/tif_aux.c b/libtiff/tif_aux.c
index 2b52e11c..53d4a6cf 100644
--- a/libtiff/tif_aux.c
+++ b/libtiff/tif_aux.c
@@ -1,4 +1,4 @@
-/* $Id: tif_aux.c,v 1.20.2.1 2010-06-08 18:50:41 bfriesen Exp $ */
+/* $Id: tif_aux.c,v 1.20.2.2 2010-06-08 19:13:03 bfriesen Exp $ */
/*
* Copyright (c) 1991-1997 Sam Leffler
@@ -48,7 +48,9 @@ _TIFFCheckRealloc(TIFF* tif, tdata_t buffer,
if (cp == NULL)
TIFFErrorExt(tif->tif_clientdata, tif->tif_name,
- "No space %s", what);
+ "Failed to allocate memory for %s "
+ "(%ld elements of %ld bytes each)",
+ what,(long) nmemb, (long) elem_size);
return cp;
}