Yeah, the casting on the port is wrong, somebody is guilty having decided to
use a signed short for it, when really at least an unsigned short is needed. I
never got around to fixing it because the short is used in bunch of places.
Feel free to do so yourself.

AFAIK 77777 is illegal though.

On Thu, 13 Apr 2000, Bill Trost wrote:
> Thanks for reporting the problem, Paul, and your patience on getting a
> response.
> 
> Paul Jimenez writes:
>         java.lang.IllegalArgumentException: port out range:77777
>                 at java.net.Socket.<init>(Socket.java:201)
>                 at java.net.Socket.<init>(Socket.java:109)
>                 at 
> Freenet.tcpConnection$ConnectThread.run(tcpConnection.java:23)
> 
>         looks alot like GIGO to me, maybe.
> 
> There have been entries for 127.0.0.1:77777 on inform.php, so that's
> where your garbage is coming from.
> 
>       Perhaps relatedly, my log files have a couple of entries with
>       negative port numbers:
> 
> Tsk, tsk.  I think the boo-boo is in tcpConnection.getPeerAddress -- the
> port is being cast to short, when a char is more appropriate.
> 
> Actually, is there any reason for this cast at all?  All users of the
> result take an int for a port.
> 
>         11-Apr-00 6:36:50 
> PM:ConnectionHandler.java#178:Normal:35c1e3d97e2c1c74
>         - DataReply -> tcp/208.219.36.67:-1542
>         11-Apr-00 6:38:08 
> PM:ConnectionHandler.java#181:Normal:69fd3257e91300f0
>         - HandshakeRequest <- tcp/208.219.36.67:-1139
>         11-Apr-00 6:38:08 
> PM:ConnectionHandler.java#181:Normal:69fd3257e91300f0
>         - HandshakeReply -> tcp/208.219.36.67:-1139
>         11-Apr-00 6:38:09 
> PM:ConnectionHandler.java#181:Normal:d390fd89161b9ca3
>         - DataRequest <- tcp/208.219.36.67:-1139
>         11-Apr-00 6:38:09 PM:message/DataRequest.java:Error:Error loading 
> EEE9CB08809B5FB81D5B119BD95540B5762AFD28 from DataStore: 
> Freenet.node.DataNotReadyException
>         11-Apr-00 6:38:09 PM:Node.java:Error:Connection Error: 
> Freenet.ConnectTimedOutException
> 
> _______________________________________________
> Freenet-dev mailing list
> Freenet-dev at lists.sourceforge.net
> http://lists.sourceforge.net/mailman/listinfo/freenet-dev
-- 

Oskar Sandberg

md98-osa at nada.kth.se

#!/bin/perl -sp0777i<X+d*lMLa^*lN%0]dsXx++lMlN/dsM0<j]dsj
$/=unpack('H*',$_);$_=`echo 16dio\U$k"SK$/SM$n\EsN0p[lN*1
lK[d2%Sa2/d0$^Ixp"|dc`;s/\W//g;$_=pack('H*',/((..)*)$/)

_______________________________________________
Freenet-dev mailing list
Freenet-dev at lists.sourceforge.net
http://lists.sourceforge.net/mailman/listinfo/freenet-dev

Reply via email to