Re: bind() allowed to non-local addresses

From: David Woodhouse (dwmw2@infradead.org)
Date: Fri Oct 20 2000 - 05:07:25 EST


mpeterson@calderasystems.com said:
> There is NOT a bug in the JVM code that handles java.net.DatagramSock
> et. Don't you find it a little compelling that the nearly identical
> JVM code passes the Java Compatibility test suite on Linux 2.2,
> Solaris, HPUX, SCO, and even Windows?

If the JVM spec says that it 'MUST' fail when used on a non-local address,
and the POSIX spec for bind does not say that it 'MUST' fail, then yes,
there is a bug in the JVM if it assumes that the two are compatible.

The fact that they just happen to behave the same in certain phases of the
moon and on other operating systems is not relevant.

We may decide that we want to pander to this brokenness, especially given
the widespread nature of the false assumption that bind() will fail when
given a non-local address. But that doesn't make the JVM non-broken.

--
dwmw2

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Oct 23 2000 - 21:00:16 EST