From: Felipe Pena Date: Thu, 4 Aug 2011 10:56:59 +0000 (+0000) Subject: - Added missing check (thanks neweracracker at gmail dot com) X-Git-Tag: php-5.3.7RC5~56 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=32319a142f671015d567358f898b3a841d21cd3d;p=php - Added missing check (thanks neweracracker at gmail dot com) --- diff --git a/ext/intl/grapheme/grapheme_string.c b/ext/intl/grapheme/grapheme_string.c index 095cc2a046..769ff7ddbb 100755 --- a/ext/intl/grapheme/grapheme_string.c +++ b/ext/intl/grapheme/grapheme_string.c @@ -519,8 +519,9 @@ PHP_FUNCTION(grapheme_substr) /* Set error messages. */ intl_error_set_custom_msg( NULL, "Error converting output string to UTF-8", 0 TSRMLS_CC ); - - efree( sub_str ); + if (sub_str) { + efree( sub_str ); + } RETURN_FALSE; }