Listening in a specified range of ports
Listening in a specified range of ports
- Subject: Listening in a specified range of ports
- From: Alessandro Volz <email@hidden>
- Date: Sat, 10 Aug 2002 20:20:06 +0200
in OT...
Currently, here's how I handle a tcp,tlisten endpoint:
case T_OPENCOMPLETE:
OTInitInetAddress(&inetAddress, kOTAnyInetAddress, kOTAnyInetAddress);
(**dcc).listenBind.addr.len = (**dcc).listenBind.addr.maxlen =
sizeof(InetAddress);
(**dcc).listenBind.addr.buf = (UInt8*)&(**dcc).listenIAdd;
(**dcc).listenBind.qlen = 1;
if ((osStatus = OTBind((**dcc).listener, &(**dcc).listenBind,
&(**dcc).listenBind)) != kOTNoError) {
} break;
case T_BINDCOMPLETE:
// listening on (**dcc).listenIAdd.fPort
break;
case T_LISTEN:
break;
case T_ACCEPTCOMPLETE:
break;
but let's say i want the user to be able to specify the port range my
application should listen... like 1024..4098
how can i modify the upper code to support this? or is this to be set at
system configuration level?
thanks in advance!
ALE
_______________________________________________
macnetworkprog mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/macnetworkprog
Do not post admin requests to the list. They will be ignored.