UDP: binding to a specific interface

Klacke <>
Mon Nov 25 10:51:41 CET 2002

On Sun, Nov 24, 2002 at 04:53:19PM +1300, Bruce Fitzsimons wrote:
> Guys'n'gals,
> I've just been spelunking the api docs, but I can't see a way to only listen
> to one interface (aka IP address) on a multi-interface machine. Surely there
> must be a way?

gen_tcp:listen(Port, [{ip, {127,0,0,1}}]).

There are many many undocumented options for sockets.
Tony Rogvall wrote that code some 5 years ago and it is still not
documented. You need to read the code. Start with inet.erl


Claes Wikstrom                        -- Caps lock is nowhere and
Alteon WebSystems                     -- everything is under control          
cellphone: +46 70 2097763

More information about the erlang-questions mailing list