]> granicus.if.org Git - php/commitdiff
Fix newly introduced crash on a file-not-found
authorRasmus Lerdorf <rasmus@php.net>
Sat, 4 Aug 2001 18:08:13 +0000 (18:08 +0000)
committerRasmus Lerdorf <rasmus@php.net>
Sat, 4 Aug 2001 18:08:13 +0000 (18:08 +0000)
ext/exif/exif.c

index 7abb061cf6f346c4f131b997c248ba5e8b3cf0e8..d7a4e009b19ff898546dd651f2c29f81d7e96073 100644 (file)
@@ -1137,7 +1137,7 @@ PHP_FUNCTION(read_exif_data)
 
        ret = php_read_jpeg_exif(&ImageInfo, Z_STRVAL_PP(p_name), readall);
 
-       if (array_init(return_value) == FAILURE) {
+       if (ret==FALSE || array_init(return_value) == FAILURE) {
                RETURN_FALSE;
        }
        add_assoc_string(return_value,"FileName",ImageInfo.FileName,1);