Opened 12 years ago
Closed 10 years ago
#4010 closed defect (fixed)
GDALFillNoData(): use of uninitialized memory
|Reported by:||Even Rouault||Owned by:||warmerdam|
valgrind --trace-children=yes python swig/python/scripts/gdal_fillnodata.py byte.asc out.tif
Conditional jump or move depends on uninitialised value(s) ==20666== at 0x710968B: GDALFillNodata (rasterfill.cpp:707) ==20666== by 0x666524E: FillNodata(void*, void*, double, int, char**, int (*)(double, char const*, void*), void*) (gdal_wrap.cpp:4669) ==20666== by 0x66696E2: _wrap_FillNodata (gdal_wrap.cpp:18021) ==20666== by 0x4A8783: PyEval_EvalFrameEx (in /usr/bin/python2.6) ==20666== by 0x4A9670: PyEval_EvalCodeEx (in /usr/bin/python2.6) ==20666== by 0x4A9741: PyEval_EvalCode (in /usr/bin/python2.6) ==20666== by 0x4C9A0D: PyRun_FileExFlags (in /usr/bin/python2.6) ==20666== by 0x4C9C23: PyRun_SimpleFileExFlags (in /usr/bin/python2.6) ==20666== by 0x41A7FE: Py_Main (in /usr/bin/python2.6) ==20666== by 0x5EECC4C: (below main) (libc-start.c:226)
I presume this is due to the double adfQuadValue; at line 694 not being initialized, but being tested in the QUAD_CHECK() macro in if( quad_value != nNoDataVal ). I am not sure which value should be used to initialize adfQuadValue[i] : 0 ?
Change History (4)
by , 12 years ago
by , 10 years ago
comment:1 by , 10 years ago
Note: See TracTickets for help on using tickets.
0 seems to be a reasonable value.