From: dean at deansas dot org Operating system: PHP version: 5.3.18 Package: SOAP related Bug Type: Bug Bug description:Fatal errors may be thrown when turning off exceptions
Description: ------------ When disabling exceptions in the constructor to SoapClient, I did not expect that for some errors it would trigger warnings and fatal errors. I did expect that it would return SoapFault objects instead, as documented on http://uk3.php.net/manual/en/function.is-soap-fault.php. In the event that this is expected behaviour then the documentation should make this clear. Test script: --------------- // URL requiring http auth and passing incorrect username & password $foo = new SoapClient("http://example.com/foo.wsdl", array( 'login' => 'bar', 'password' => 'baz', 'exceptions' => false)); print $foo; Expected result: ---------------- That $foo is a SoapFault object, no warnings/errors are thrown and something like the below is output: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://example.com/foo.wsdl' : failed to load external entity "http://example.com/foo.wsdl" in test.php:4 Stack trace: #0 test.php(4): SoapClient->SoapClient('http://example....', Array) #1 {main} Actual result: -------------- Warning: SoapClient::SoapClient(http://example.com/foo.wsdl): failed to open stream: HTTP request failed! HTTP/1.1 401 Authorization Required in test.php on line 4 Warning: SoapClient::SoapClient(): I/O warning : failed to load external entity "http://example.com/foo.wsdl" in test.php on line 4 Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://example.com/foo.wsdl' : failed to load external entity "http://example.com/foo.wsdl" in test.php on line 4 -- Edit bug report at https://bugs.php.net/bug.php?id=63474&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=63474&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=63474&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=63474&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=63474&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=63474&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=63474&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=63474&r=needscript Try newer version: https://bugs.php.net/fix.php?id=63474&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=63474&r=support Expected behavior: https://bugs.php.net/fix.php?id=63474&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=63474&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=63474&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=63474&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=63474&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=63474&r=dst IIS Stability: https://bugs.php.net/fix.php?id=63474&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=63474&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=63474&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=63474&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=63474&r=mysqlcfg
