/* Decoded by unphp.net */ --TEST-- Bug #69337 (Stream context leaks when http request fails) --SKIPIF-- --INI-- allow_url_fopen=1 --FILE-- "stream_notification_callback")); $responses = array( "data://text/plain,HTTP/1.0 302 Found Location: /try-again ", "data://text/plain,HTTP/1.0 404 Not Found ", ); ['pid' => $pid, 'uri' => $uri] = http_server($responses, $output); $f = file_get_contents($uri, 0, $ctx); http_server_kill($pid); var_dump($f); ?> --EXPECTF-- Warning: file_get_contents(http://%s:%d): Failed to open stream: HTTP request failed! HTTP/1.0 404 Not Found%ain %s on line %d bool(false)