[kaffe] Re: NetworkInterface problem
robilad at kaffe.org
Sun Apr 24 15:32:35 PDT 2005
Ito Kazumitsu wrote:
> From: Ito Kazumitsu <kaz at maczuka.gcd.org>
> Subject: NetworkInterface problem (Re: [kaffe] freebsd 5.3 failed regression)
> Date: Sun, 24 Apr 2005 23:07:48 +0900 (JST)
>>The problem seems to appear when a network interface has more than
> The differnce between Kaffe's java.net.NetworkInterface and
> that of GNU classpath is that Kaffe's has a private method
> "condense" which condenses the output from
> The output from VMNetworkInterface.getInterfaces() may be
> something like this.
> ((name1 addr11) (name1 addr12) (name1 addr13)
> (name2 addr21) (name2 addr22))
> condense condenses this into
> ((name1 (addr11 addr12 addr13))
> (name2 (addr21 addr22)))
>> (1) NetworkInterface returned by NetworkInterface.getNetworkInterfaces()
>> contains all addresses of that interface.
> NetworkInterface.getNetworkInterfaces() returns the the condensed
>> (2) NetworkInterface returned by NetworkInterface.getByName(name) or
>> NetworkInterface.getByInetAddress(addr) contains only one of the
>> addresses of that interface.
> Until recently, these methods used getNetworkInterfaces() which
> returned a condensed result. But now they do not call
> getNetworkInterfaces() but calls VMNetworkInterface.getInterfaces()
> which may return one of uncondensed raw results.
> The fix may be either
> (a) To modify java.net.NetworkInterface so that getByName or
> getByInetAddress calls getNetworkInterfaces() as before.
Thanks for the fast analysis, Ito!
I'd say let's do a) as it is simpler & faster. We need to push the
condensing code upstream into classpath anyway for IPv6 support, I think.
Could you write a patch?
p.s. I hope the recent iconv changes work for you on freebsd. Riccardo
seems to be having some problems, we're debugging them on IRC.
More information about the kaffe