summaryrefslogtreecommitdiff
path: root/libtiff/tiffio.h
diff options
context:
space:
mode:
authorEven Rouault <even.rouault@spatialys.com>2022-11-22 18:17:34 +0100
committerEven Rouault <even.rouault@spatialys.com>2022-11-22 18:17:34 +0100
commitb88c3f9af25955a0df90a2f4fc2ac75fd4cce209 (patch)
tree60cc993fd9860cd4998350abcb1762ca9fcd4e29 /libtiff/tiffio.h
parentd95b5b7628da6e0f446f7289059e1248de12dec9 (diff)
downloadlibtiff-git-b88c3f9af25955a0df90a2f4fc2ac75fd4cce209.tar.gz
Add TIFFOpenOptionsSetMaxSingleMemAlloc()
to define a limit in bytes for a single memory allocation done by libtiff. Also add internal functions used in replacement of the non Ext ones: void* _TIFFmallocExt(TIFF* tif, tmsize_t s); void* _TIFFcallocExt(TIFF* tif, tmsize_t nmemb, tmsize_t siz); void* _TIFFreallocExt(TIFF* tif, void* p, tmsize_t s); void _TIFFfreeExt(TIFF* tif, void* p);
Diffstat (limited to 'libtiff/tiffio.h')
-rw-r--r--libtiff/tiffio.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/libtiff/tiffio.h b/libtiff/tiffio.h
index 7d12a88c..54a646d8 100644
--- a/libtiff/tiffio.h
+++ b/libtiff/tiffio.h
@@ -466,6 +466,7 @@ extern void TIFFErrorExtR(TIFF*, const char*, const char*, ...) TIFF_ATTRIBUTE((
typedef struct TIFFOpenOptions TIFFOpenOptions;
extern TIFFOpenOptions* TIFFOpenOptionsAlloc(void);
extern void TIFFOpenOptionsFree(TIFFOpenOptions*);
+extern void TIFFOpenOptionsSetMaxSingleMemAlloc(TIFFOpenOptions* opts, tmsize_t max_single_mem_alloc);
extern void TIFFOpenOptionsSetErrorHandlerExtR(TIFFOpenOptions* opts, TIFFErrorHandlerExtR handler, void* errorhandler_user_data);
extern void TIFFOpenOptionsSetWarningHandlerExtR(TIFFOpenOptions* opts, TIFFErrorHandlerExtR handler, void* warnhandler_user_data);