Amos Shapira wrote:
On 29/07/07, *Gilad Ben-Yossef* <[EMAIL PROTECTED]
<mailto:[EMAIL PROTECTED]>> wrote:
guy keren wrote:
> here is something interesting: man 7 socket
> and look for 'SO_BINDTODEVICE'
You might find the following example useful:
http://www.codefidence.com/src/bindtodevice.c
What's wrong with a simple bind(address, port-zero)? It works for me.
--Amos
the only wrong thing about it, was that i did not think about it ;)
actually, i thought there ought to be a PORT_ANY or similar constant,
and when i didn't find it in the man or the headers, i just looked for
other options.
i sent my mail before i saw yours, or i wouldn't have bothered ;)
the only question regarding what you found, is whether this is a
supported feature, or a "bug", that might get "fixed" in a later version
of the kernel.if it's a feture, it surely is simple enough to use. note
that unlike you, i didn't test my method, so currently shachar has only
one sure method - your method.
--guy
=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]