From 10c47ef2af59dfba47633520faa9302af90a9ae7 Mon Sep 17 00:00:00 2001 From: scuri Date: Tue, 26 Jan 2010 15:56:35 +0000 Subject: *** empty log message *** --- src/libtiff/tif_aux.c | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) (limited to 'src/libtiff/tif_aux.c') diff --git a/src/libtiff/tif_aux.c b/src/libtiff/tif_aux.c index 7500295..2012f19 100644 --- a/src/libtiff/tif_aux.c +++ b/src/libtiff/tif_aux.c @@ -1,4 +1,4 @@ -/* $Id: tif_aux.c,v 1.3 2009/12/11 15:17:41 scuri Exp $ */ +/* $Id: tif_aux.c,v 1.4 2010/01/26 15:56:36 scuri Exp $ */ /* * Copyright (c) 1991-1997 Sam Leffler @@ -34,8 +34,7 @@ #include tdata_t -_TIFFCheckRealloc(TIFF* tif, tdata_t buffer, - size_t nmemb, size_t elem_size, const char* what) +_TIFFCheckMalloc(TIFF* tif, size_t nmemb, size_t elem_size, const char* what) { tdata_t cp = NULL; tsize_t bytes = nmemb * elem_size; @@ -44,19 +43,12 @@ _TIFFCheckRealloc(TIFF* tif, tdata_t buffer, * XXX: Check for integer overflow. */ if (nmemb && elem_size && bytes / elem_size == nmemb) - cp = _TIFFrealloc(buffer, bytes); + cp = _TIFFmalloc(bytes); if (cp == NULL) - TIFFErrorExt(tif->tif_clientdata, tif->tif_name, - "No space %s", what); - - return cp; -} + TIFFErrorExt(tif->tif_clientdata, tif->tif_name, "No space %s", what); -tdata_t -_TIFFCheckMalloc(TIFF* tif, size_t nmemb, size_t elem_size, const char* what) -{ - return _TIFFCheckRealloc(tif, NULL, nmemb, elem_size, what); + return (cp); } static int -- cgit v1.2.3