From: blueshade at wave460 dot net Operating system: debian sarge on linux 2.4.27 PHP version: 5.1.4 PHP Bug Type: Streams related Bug description: fopen wrapper doesn't fail on invalid hostname with curlwrappers enabled
Description: ------------ when compiled with "--with-curlwrappers", php 5.1.4 fails to fail an fopen request when you provide it with a uri containing an invalid host name, when recompiled without "--with-curlwrappers", it fails as expected... this results in php invalidly returing a valid fopen resource even if the remote host is unreachable (e.g. because of a network problem) Reproduce code: --------------- <? $file = fopen('http://non.existent.host', 'rb'); print_r($file); echo "\n"; ?> Expected result: ---------------- it should display a warning (if enabled) and return "false" in $file Actual result: -------------- with "--with-curlwrappers", it returns "Resource id #5" in $file and doesn't warn of an error whatsoever -- Edit bug report at http://bugs.php.net/?id=38269&edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=38269&r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=38269&r=trysnapshot52 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=38269&r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=38269&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=38269&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=38269&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=38269&r=needscript Try newer version: http://bugs.php.net/fix.php?id=38269&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=38269&r=support Expected behavior: http://bugs.php.net/fix.php?id=38269&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=38269&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=38269&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=38269&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=38269&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=38269&r=dst IIS Stability: http://bugs.php.net/fix.php?id=38269&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=38269&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=38269&r=float No Zend Extensions: http://bugs.php.net/fix.php?id=38269&r=nozend MySQL Configuration Error: http://bugs.php.net/fix.php?id=38269&r=mysqlcfg