Bug #17074 Updated: Cannot bind() a socket to a specific port in FreeBSD
ID: 17074
Updated by: jason@php.net
Reported By: antonio.bonifati@polimi.it
-Status: Open
+Status: Assigned
Bug Type: Sockets related
Operating System: FreeBSD
PHP Version: 4.2.0
-Assigned To:
+Assigned To: jason@php.net
New Comment:
Thanks for the report antonio.
From an initial glance, the fix you suggest looks correct, however, I
still need to run it through a few tests.
Thanks,
-Jason
Previous Comments:
------------------------------------------------------------------------
[2002-05-07 10:48:23] antonio.bonifati@polimi.it
please see also bug #10830
this bug hasn't been fixed yet in php 4.2.0
could you fix it?
i fixed it for myself changing the line 1001
in ext/sockets/sockets.c:
retval = bind(php_sock->bsd_socket, (struct sockaddr *)sa,
sizeof(sa_storage));
with this one:
retval = bind(php_sock->bsd_socket, (struct sockaddr *)sa,
sizeof(struct sockaddr));
it seems that the last parameter to bind is broken
best regards
Antonio
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17074&edit=1
Thread (4 messages)