From: Enlightenment S. <no-...@en...> - 2008-12-29 09:39:07
|
Log: Check decompression error. Potential bug detected by llvm static analyser. Author: cedric Date: 2008-12-29 01:39:03 -0800 (Mon, 29 Dec 2008) New Revision: 38341 Modified: trunk/eet/src/lib/eet_image.c Modified: trunk/eet/src/lib/eet_image.c =================================================================== --- trunk/eet/src/lib/eet_image.c 2008-12-29 09:03:24 UTC (rev 38340) +++ trunk/eet/src/lib/eet_image.c 2008-12-29 09:39:03 UTC (rev 38341) @@ -644,7 +644,7 @@ (Bytef *)(d + 32), (uLong)(w * h * 4), compression); - if (buflen > (w * h * 4)) + if (ret != Z_OK || buflen > (w * h * 4)) { free(comp); free(d); |