[nycphp-talk] xdebug / socket_accept()
anoland at indigente.net
Sun Jan 17 11:28:27 EST 2010
This isn't really a good way to go about testing the xdebug connection.I
tried it on my machine and got the same errors you did. Depending on the
configuration, the debugger opens port 9000 either during httpd start or the
page runtime. Either way port 9000 is already in use by the time your socket
tries to connect.
Make sure that phpinfo shows the extension is loaded, and that the thread
safety matches all three: httpd, php, and xdebug. If you are using WAMP make
sure the VC versions match as well.
Turn on error logging in httpd, php, and xdebug and make sure they don't
have any problems.
Also, try this to test instead.
On Sat, Jan 16, 2010 at 6:21 PM, Yitzchak Schaffer <
yitzchak.schaffer at gmx.com> wrote:
> Still working on my xdebug woes; I finished reading the instrux at
> but the test script still fails. The script:
> $address = '127.0.0.1';
> $port = 9000;
> $sock = socket_create(AF_INET, SOCK_STREAM, 0);
> socket_bind($sock, $address, $port) or die('Unable to bind');
> $client = socket_accept($sock);
> Each of the three var_dump()'s returns "resource(2, Socket)" but
> socket_accept() errors out with " Warning: socket_accept()
> [function.socket-accept]: unable to accept incoming connection : Invalid
> argument in /www/websites/emeraldview/public/test.php on line 8"
> Any ideas?
> Many thanks,
> Yitzchak Schaffer
> Systems Manager
> Touro College Libraries
> 33 West 23rd Street
> New York, NY 10010
> Tel (212) 463-0400 x5230
> Fax (212) 627-3197
> Email yitzchak.schaffer at tourolib.org
> Access Problems? Contact systems.library at touro.edu
> New York PHP Users Group Community Talk Mailing List
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the talk