View Issue Details

IDProjectCategoryView StatusLast Update
0001629XdebugUncategorizedpublic2019-02-15 15:11
ReporterNikolay_Z Assigned Toderick  
PrioritynormalSeveritymajorReproducibilityalways
Status closedResolutionfixed 
Platform*OS*OS Version7
Product Version2.7.0rc1 
Target Version2.7.0Fixed in Version2.7.0RC2 
Summary0001629: SOAP Client/Server detection code does not handle inherited classes
Description

https://bugs.php.net/bug.php?id=77601

Steps To Reproduce

<?php
class SoapAgent extends \SoapClient
{
public function construct(string $wsdl)
{
try {
parent::
construct($wsdl);
echo 'Success!' . PHP_EOL;
} catch (\Throwable $t) {
var_dump($t);
}
}
}

$client = new SoapAgent('test');

Expected result:

var_dump() of the Throwable object.

Actual result:

Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'test' : failed to load external entity "test"

Process finished with exit code 255

Additional Information

If XDebug is disabled in php.ini - soap client work as expected

TagsNo tags attached.
Operating SystemWindows
PHP Version7.3.0-7.3.1

Activities

derick

2019-02-11 10:42

administrator   ~0004878

This is specifically related to just SOAP classes. The soap extension overloads the PHP error handler to be able to throw exceptions, and as Xdebug uses it's own overloaded PHP error handler, this conflicts. This is why Xdebug tries to detect whether a SoapClient or SoapServer is a class in the error, and restores the original error handler (SOAP's). However, Xdebug does not deal with when an inherited class of SoapClient/SoapServer is used.

derick

2019-02-11 10:43

administrator   ~0004879

I have a working patch, and running tests now to see if this breaks nothing else.

derick

2019-02-11 15:21

administrator   ~0004880

Fixed in GIT — thanks for the report!

Nikolay_Z

2019-02-11 15:33

reporter   ~0004881

Thank you!

Issue History

Date Modified Username Field Change
2019-02-11 09:41 Nikolay_Z New Issue
2019-02-11 10:42 derick Note Added: 0004878
2019-02-11 10:42 derick Priority high => normal
2019-02-11 10:42 derick Severity crash => major
2019-02-11 10:42 derick OS Windows => *
2019-02-11 10:42 derick Platform Windows => *
2019-02-11 10:42 derick Summary Xdebug's error handler messes up with fatal to exception error conversions => SOAP Client/Server detection code does not handle inherited classes
2019-02-11 10:43 derick Note Added: 0004879
2019-02-11 10:43 derick Assigned To => derick
2019-02-11 10:43 derick Status new => assigned
2019-02-11 15:21 derick Note Added: 0004880
2019-02-11 15:21 derick Status assigned => closed
2019-02-11 15:21 derick Resolution open => fixed
2019-02-11 15:21 derick Fixed in Version => 2.7.0
2019-02-11 15:33 Nikolay_Z Note Added: 0004881
2019-02-15 15:10 derick Fixed in Version 2.7.0 => 2.7.0RC2
2019-02-15 15:11 derick Target Version => 2.7.0
2020-03-12 16:35 derick Category Usage problems (Wrong Results) => Variable Display
2020-03-12 16:38 derick Category Variable Display => Uncategorized