Hi,
there is an error in parameters handling, because inet.txt doc says that:
hb_InetServer( port [, cBindAddr [, nListenLimit]] ) --> SOCKET
but internally function will check only 2 params and 2nd parameter as
socket that it could reuse.
so I have changed line 994 in source\rtl\hbinet.c from:
if( ! HB_ISNUM( 1 ) || ( socket == NULL && ! HB_ISNIL( 2 )) )
{
hb_inetErrRT();
return;
}
to
if( ! HB_ISNUM( 1 ) || ( socket == NULL && ! ( HB_ISNIL( 2 ) ||
HB_ISCHAR( 2 ) ) ) || ( ! HB_ISNIL( 3 ) && ! HB_ISNUM( 3 ) ) )
{
hb_inetErrRT();
return;
}
and now it correct handles parameters (also if I not checked too much
with other existent applications). Now could anyone check me if this is
correct? If yes, how change inet.txt doc description? is it correct to
write:
hb_InetServer( port [, SOCKET | cBindAddr [, nListenLimit]] ) --> SOCKET
and describing in text that only if SOCKET is not passed as second
parameter nListenLimit is used (notation doubt) ?
Best Regards,
Francesco
_______________________________________________
Harbour mailing list
Harbour@harbour-project.org
http://lists.harbour-project.org/mailman/listinfo/harbour