pajoye Tue, 15 Feb 2011 14:02:26 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=308362
Log: - fix the fix (Dmitry) and ensure that it builds everywhere, can someone test on solaris&co pls? Changed paths: U php/php-src/branches/PHP_5_3/ext/exif/exif.c U php/php-src/trunk/ext/exif/exif.c Modified: php/php-src/branches/PHP_5_3/ext/exif/exif.c =================================================================== --- php/php-src/branches/PHP_5_3/ext/exif/exif.c 2011-02-15 13:46:34 UTC (rev 308361) +++ php/php-src/branches/PHP_5_3/ext/exif/exif.c 2011-02-15 14:02:26 UTC (rev 308362) @@ -40,8 +40,14 @@ #include "php.h" #include "ext/standard/file.h" +#ifdef HAVE_STDINT_H +# include <stdint.h> +#endif +#ifdef HAVE_INTTYPES_H +# include <inttypes.h> +#endif #ifdef PHP_WIN32 -#include "win32/php_stdint.h" +# include "win32/php_stdint.h" #endif #if HAVE_EXIF @@ -2857,7 +2863,7 @@ byte_count_signed = (int64_t)components * php_tiff_bytes_per_format[format]; - if (byte_count_signed < 0 || (byte_count_signed > 2147483648)) { + if (byte_count_signed < 0 || (byte_count_signed > INT32_MAX)) { exif_error_docref("exif_read_data#error_ifd" EXIFERR_CC, ImageInfo, E_WARNING, "Process tag(x%04X=%s): Illegal byte_count", tag, exif_get_tagname(tag, tagname, -12, tag_table TSRMLS_CC)); return FALSE; } Modified: php/php-src/trunk/ext/exif/exif.c =================================================================== --- php/php-src/trunk/ext/exif/exif.c 2011-02-15 13:46:34 UTC (rev 308361) +++ php/php-src/trunk/ext/exif/exif.c 2011-02-15 14:02:26 UTC (rev 308362) @@ -40,8 +40,14 @@ #include "php.h" #include "ext/standard/file.h" +#ifdef HAVE_STDINT_H +# include <stdint.h> +#endif +#ifdef HAVE_INTTYPES_H +# include <inttypes.h> +#endif #ifdef PHP_WIN32 -#include "win32/php_stdint.h" +# include "win32/php_stdint.h" #endif #if HAVE_EXIF @@ -2853,7 +2859,7 @@ byte_count_signed = (int64_t)components * php_tiff_bytes_per_format[format]; - if (byte_count_signed < 0 || (byte_count_signed > 2147483648)) { + if (byte_count_signed < 0 || (byte_count_signed > INT32_MAX)) { exif_error_docref("exif_read_data#error_ifd" EXIFERR_CC, ImageInfo, E_WARNING, "Process tag(x%04X=%s): Illegal byte_count", tag, exif_get_tagname(tag, tagname, -12, tag_table TSRMLS_CC)); return FALSE; }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php