* BOB, SAM, i2psnark: Fix datagram NPE (ticket #1275)

This could only happen on an extremely overloaded router.
This commit is contained in:
zzz
2014-05-13 18:45:54 +00:00
parent 197be5f60f
commit 8480a204ea
5 changed files with 13 additions and 3 deletions

View File

@@ -106,8 +106,10 @@ public class UDPIOthread implements I2PSessionListener, Runnable {
// _log.debug("Message available: id = " + msgId + " size = " + size);
try {
byte msg[] = session.receiveMessage(msgId);
out.write(msg);
out.flush();
if (msg != null) {
out.write(msg);
out.flush();
}
} catch (I2PSessionException ise) {
up = false;
} catch (IOException ioe) {