Ticket #2960 (closed defect: fixed)
Lanczos and CubicSpline resampler buffer error on 2x2 images
| Reported by: | warmerdam | Owned by: | rouault |
|---|---|---|---|
| Priority: | high | Milestone: | 1.6.1 |
| Component: | Algorithms | Version: | 1.6.0 |
| Severity: | normal | Keywords: | warp api lanczos |
| Cc: | sprice, dron, rouault, chaitanya |
Description
The following command:
gdalwarp -r lanczos test.tif testwarp.tif
on the attached file produces the following valgrind report on linux and in some cases crashes gdalwarp on windows.
==7974== Invalid read of size 2 ==7974== at 0x550E86D: GWKGetPixelRow(GDALWarpKernel*, int, int, int, double*, double*, double*) (gdalwarpkernel.cpp:1195) ==7974== by 0x5510068: GWKResample(GDALWarpKernel*, int, double, double, double*, double*, double*, GWKResampleWrkStruct const*) (gdalwarpkernel.cpp:2049) ==7974== by 0x5510CF3: GWKGeneralCase(GDALWarpKernel*) (gdalwarpkernel.cpp:2483) ==7974== by 0x55115DB: GDALWarpKernel::PerformWarp() (gdalwarpkernel.cpp:660) ==7974== by 0x55132EF: GDALWarpOperation::WarpRegionToBuffer(int, int, int, int, void*, GDALDataType, int, int, int, int) (gdalwarpoperation.cpp:1579) ==7974== by 0x5513ACB: GDALWarpOperation::WarpRegion(int, int, int, int, int, int, int, int) (gdalwarpoperation.cpp:1186) ==7974== by 0x55143A9: GDALWarpOperation::ChunkAndWarpImage(int, int, int, int) (gdalwarpoperation.cpp:659) ==7974== by 0x406B31: main (gdalwarp.cpp:933) ==7974== Address 0xAF64478 is 0 bytes after a block of size 16 alloc'd ==7974== at 0x4C21C16: malloc (vg_replace_malloc.c:149) ==7974== by 0x54EA912: VSIMalloc (cpl_vsisimple.cpp:300) ==7974== by 0x5512820: GDALWarpOperation::WarpRegionToBuffer(int, int, int, int, void*, GDALDataType, int, int, int, int) (gdalwarpoperation.cpp:1337) ==7974== by 0x5513ACB: GDALWarpOperation::WarpRegion(int, int, int, int, int, int, int, int) (gdalwarpoperation.cpp:1186) ==7974== by 0x55143A9: GDALWarpOperation::ChunkAndWarpImage(int, int, int, int) (gdalwarpoperation.cpp:659) ==7974== by 0x406B31: main (gdalwarp.cpp:933)
Attachments
Change History
Note: See
TracTickets for help on using
tickets.

