mina-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emmanuel Lecharny <elecha...@gmail.com>
Subject Last version on trunk may have issues
Date Fri, 12 Feb 2010 10:07:41 GMT
Hi gys,

yesturday I tried to fix the Datagram bug (DIRMINA-732). I think it 
works on linux, I have no idea for windows (if someone can give it a 
try), and I know it fails on Mac OSX.

The problem is that if we register the 'any' address ( on a 
datagram acceptor, and try to get a session from it, like the way it's 
done on the failng test :

         InetSocketAddress bindAddress = new InetSocketAddress(  
         acceptor.setHandler(new TestHandler());
         IoSession session = acceptor.newSession(new InetSocketAddress(
                 "", AvailablePortFinder.getNextAvailable()), 

we get an error, as the bindAddress is considered as a Inet4Address, 
when the acceptor is bound on a Inet6Address. As we store the address in 
a hashMap to check if they are equals, we have an issue, because 
whatever you do, a Inet4Address will always be different from a 
Inet6Address; I hacked the code atrociously by using a String 
translation for this address, but it does not work on Mac.

Now, I'm dubious about the test. Why should be grab a session from the 
acceptor ?
If someone has some idea about what's wrong about this test, that would 
be great !

Emmanuel L├ęcharny

View raw message