summaryrefslogtreecommitdiff
path: root/ext/exif/exif.c
diff options
context:
space:
mode:
authorStanislav Malyshev <stas@php.net>2017-01-02 21:01:35 -0800
committerStanislav Malyshev <stas@php.net>2017-01-02 21:01:35 -0800
commit7f0de1a138a69beb7c537fd1ec84afbc91a45b19 (patch)
treedf65461e23b5ac1365bcb0136a60237587cab5bd /ext/exif/exif.c
parentd2298c3cecd1cc4a4c48173b3cce9aa9b6f409bd (diff)
parentfa2125df6766bb7edac0a0bf433940465da9af4b (diff)
downloadphp-git-7f0de1a138a69beb7c537fd1ec84afbc91a45b19.tar.gz
Merge branch 'PHP-5.6' into PHP-7.0
* PHP-5.6: Fix bug #73737 FPE when parsing a tag format Fix bug #73773 - Seg fault when loading hostile phar Fix bug #73825 - Heap out of bounds read on unserialize in finish_nested_data() Fix bug #73768 - Memory corruption when loading hostile phar Fix int overflows in phar (bug #73764)
Diffstat (limited to 'ext/exif/exif.c')
-rw-r--r--ext/exif/exif.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/exif/exif.c b/ext/exif/exif.c
index 86cf173301..989c73fbd7 100644
--- a/ext/exif/exif.c
+++ b/ext/exif/exif.c
@@ -1297,7 +1297,7 @@ static size_t exif_convert_any_to_int(void *value, int format, int motorola_inte
if (s_den == 0) {
return 0;
} else {
- return php_ifd_get32s(value, motorola_intel) / s_den;
+ return (size_t)((double)php_ifd_get32s(value, motorola_intel) / s_den);
}
case TAG_FMT_SSHORT: return php_ifd_get16u(value, motorola_intel);