Mute the connection reset by peer exception - it's spamilicious for the most part.

This commit is contained in:
cpw 2016-06-12 12:15:10 -04:00
parent ee7c965fe0
commit f7feec029e
1 changed files with 9 additions and 1 deletions

View File

@ -562,7 +562,15 @@ public class NetworkDispatcher extends SimpleChannelInboundHandler<Packet<?>> im
// Stop the epic channel closed spam at close // Stop the epic channel closed spam at close
if (!(cause instanceof ClosedChannelException)) if (!(cause instanceof ClosedChannelException))
{ {
FMLLog.log(Level.ERROR, cause, "NetworkDispatcher exception"); // Mute the reset by peer exception - it's disconnection noise
if (cause.getMessage().contains("Connection reset by peer"))
{
FMLLog.log(Level.DEBUG, cause, "Muted NetworkDispatcher exception");
}
else
{
FMLLog.log(Level.ERROR, cause, "NetworkDispatcher exception");
}
} }
super.exceptionCaught(ctx, cause); super.exceptionCaught(ctx, cause);
} }