]> granicus.if.org Git - php/commitdiff
MFH:
authorFelipe Pena <felipe@php.net>
Thu, 8 Jan 2009 19:21:25 +0000 (19:21 +0000)
committerFelipe Pena <felipe@php.net>
Thu, 8 Jan 2009 19:21:25 +0000 (19:21 +0000)
- Fixed bug #47037 (No error when using fopen with emty string)
Patch by Cristian Rodriguez R.

NEWS
main/streams/streams.c

diff --git a/NEWS b/NEWS
index f24cfaf7e16d3adbf7ae68c2154ac0cd1b2c8d46..0b5a2ca0f0bd4d6b47c8ad67eb2a059dc3df818e 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -14,6 +14,8 @@ PHP                                                                        NEWS
   (Fixes CVE-2008-5498) (Scott)
 - Fixed a segfault when malformed string is passed to json_decode(). (Scott)
 
+- Fixed bug #47037 (No error when using fopen with emty string). 
+  (Cristian Rodriguez R.)
 - Fixed bug #47035 (dns_get_record returns a garbage byte at the end of a TXT 
   record). (Felipe)
 - Fixed bug #47027 (var_export doesn't show numeric indices on ArrayObject).
index 8f2bd227fcfa817c0ded9a0b6e9e010f5d30e463..4d1f7d5569cb279980ab8d9825a877993306e13d 100755 (executable)
@@ -1763,6 +1763,7 @@ PHPAPI php_stream *_php_stream_open_wrapper_ex(char *path, char *mode, int optio
        }
 
        if (!path || !*path) {
+               php_error_docref(NULL TSRMLS_CC, E_WARNING, "Filename cannot be empty");
                return NULL;
        }