2008.11.24 19:40 "[Tiff] TIFFWriteScanline corrupts buffer when compression with predication is enabled", by William B Thompson

2008.11.26 16:54 "Re: [Tiff] Memory leak opening and closing files?", by Frank Warmerdam

the following program shows a constant increase in memory usage, so I suspect a memory leak in the tiff library (using libtiff 3.8.2-1 on Windows):

     for (int i = 0; i < 1000000; ++i) {
         TIFF *f = TIFFOpen("test.tiff", "rb");
         TIFFClose(f);
     }

where "test.tiff" is generated with (in fact I observed this behavior with many different test files):

Eric,

I have done a similar test on linux with libtiff 3.8.2 and seen no signs of leakage either by running for a long time or when using valgrind on a couple iterations.

This suggests that the problem is either specific to the tif_win32.c platform specific stuff, or that it is an artifact of heap fragmentation that isn't really about libtiff.

I don't have good memory leak identification tools for win32, so I'm not inclined to do the digging on that aspect.

Best regards,
--
---------------------------------------+--------------------------------------

I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam@pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam

and watch the world go round - Rush    | Geospatial Programmer for Rent