Paul writes:
> java.lang.NullPointerException:
> at Freenet.SendFailedException.<init>(SendFailedException.java:9)
> at Freenet.Message.sendBack(Message.java:278)
> at Freenet.message.InsertReply.pReceived(InsertReply.java:33)
> at Freenet.Message.received(Message.java:166)
> at
> Freenet.node.StandardMessageHandler.handle(StandardMessageHandler.java:86)
> at Freenet.ConnectionHandler.run(ConnectionHandler.java:95)
Ah, no doubt that's the same NullPointerException that Oskar was puzzling
over this morning. The stack trace was incomplete that time due to
the use of compiled Java. Now we see that the exception is happening
one deeper on the stack than we realized. Oskar said it should throw
a ConnectFailedException, and it appears that it did so, but when it
tried to turn this into a SendFailedException there was no peer to use.
This happens when we get a second InsertReply after sending one, so we
do want to reject the message. Your fix is probably reasonable just
to suppress the spurious NullPointerException. That way we'll just log
the error and discard the message.
> So I peeked at SendFailedException.java and changed
> 9c9
> < super("Failed to connect to " + addr.toString());
> ---
> > super("Failed to connect to " + (addr==null? "NULL"
> > :addr.toString()));
Hal
_______________________________________________
Freenet-dev mailing list
Freenet-dev at lists.sourceforge.net
http://lists.sourceforge.net/mailman/listinfo/freenet-dev