Opened 16 years ago
Closed 16 years ago
#2429 closed defect (fixed)
Division by zero in GDALGetRandomRasterSample
Reported by: | Even Rouault | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | GDAL_Raster | Version: | unspecified |
Severity: | normal | Keywords: | |
Cc: |
Description
In r14723, I commited a workaround to avoid the crash, but I'm not sure this is the best thing we can do.
To reproduce that, run the new commandline utility "gdaltorture" on ../autotest/gcore/data/sasha.tif for example.
Note:
See TracTickets
for help on using tickets.
I applied a different change that might oversample, but this is harmless since we limit the total samples to the size of the buffer later on (r14750 in trunk).
I have not bothered to back port this since I assume it is an esoteric rather than a practical issue. But the change could be backported if desired.