Re: sockets extension
| From: | Sterling Hughes | Date: | Wed, 16 May 2001 08:01:45 +0000 |
| Subject: | Re: sockets extension | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-55527@lists.php.net to get a copy of this message | ||
Daniel Beulshausen wrote:
hi, i've updated the sockets extension so that it's usable under win32 as well, however it's incompatible to the "old extension" for some reasons (thats why i want some feedback): sockets fd under win32 are usigned, the previous approach of returning long's and check for < 0 wouldn't have worked, thus it's been converted to use resources (which is also cleaner behaviour IMO). the return values of most functions had to be changed, because win32 has an complete different error handling.I've been meaning for a while to do this, so yes, that's perfectly ok. I don't quite understand "the return values of most functions had to be changed because win32 has a completely different error handling". Can you elaborate a bit more. Also, strerror() is to my knowledge, available on Win32 systems (check out FormatMessage()). *ouch* I WILL NOT DO WINDOWS PROGRAMMING I WILL NOT DO WINDOWS PROGRAMMING ...
as that together would already break old scripts i've also renamed the functions to (hopefully) go with the standards.The naming looks pretty good. It seems like most people want this (I don't, but, ah well.) Nice Job! -Sterling