com php-src: improve the check, avoid strlen on NULL: ext/exif/exif.c

From: Date: Wed, 03 Aug 2016 19:29:03 +0000
Subject: com php-src: improve the check, avoid strlen on NULL: ext/exif/exif.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-93592@lists.php.net to get a copy of this message
Commit: 662e5ae9517a4f3607e5d7e8e16b6cbac675c8ac Author: Anatol Belski <ab@php.net> Wed, 3 Aug 2016 18:26:29 +0200 Committer: Davey Shafik <me@daveyshafik.com> Wed, 3 Aug 2016 12:29:03 -0700 Parents: 835ef14979c6953cbe9b4ead58649c587ccfe2ba Branches: PHP-7.1 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=662e5ae9517a4f3607e5d7e8e16b6cbac675c8ac Log: improve the check, avoid strlen on NULL Changed paths: M ext/exif/exif.c Diff: diff --git a/ext/exif/exif.c b/ext/exif/exif.c index 1dfa956..f62f77a 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -1702,10 +1702,6 @@ static void exif_iif_add_value(image_info_type *image_info, int section_index, c if (!length) break; case TAG_FMT_UNDEFINED: - if (tag == TAG_MAKER_NOTE) { - length = MIN(length, strlen(value)); - } - if (value) { if (tag == TAG_MAKER_NOTE) { length = MIN(length, strlen(value));

« previous php.cvs (#93592) next »