diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2018-06-03 11:46:55 +1200 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2018-06-03 11:46:55 +1200 |
commit | f0d1a5df7aecf1237609200d3ecb7cdd3d0abcab (patch) | |
tree | c82ad82bdb77e0e33340d6a020dc0912448f60d8 /src/org/traccar/MainEventHandler.java | |
parent | 06e3bd8b16da12baafc9a97ba5949b3f7ffb5e07 (diff) | |
download | trackermap-server-f0d1a5df7aecf1237609200d3ecb7cdd3d0abcab.tar.gz trackermap-server-f0d1a5df7aecf1237609200d3ecb7cdd3d0abcab.tar.bz2 trackermap-server-f0d1a5df7aecf1237609200d3ecb7cdd3d0abcab.zip |
Properly handle datagram channels
Diffstat (limited to 'src/org/traccar/MainEventHandler.java')
-rw-r--r-- | src/org/traccar/MainEventHandler.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/org/traccar/MainEventHandler.java b/src/org/traccar/MainEventHandler.java index 21b917a2d..49694aaff 100644 --- a/src/org/traccar/MainEventHandler.java +++ b/src/org/traccar/MainEventHandler.java @@ -18,11 +18,11 @@ package org.traccar; import io.netty.channel.Channel; import io.netty.channel.ChannelHandlerContext; import io.netty.channel.ChannelInboundHandlerAdapter; +import io.netty.channel.socket.DatagramChannel; import io.netty.handler.timeout.IdleStateEvent; import org.traccar.helper.Log; import org.traccar.model.Position; -import java.nio.channels.DatagramChannel; import java.sql.SQLException; import java.text.SimpleDateFormat; import java.util.Arrays; @@ -101,7 +101,7 @@ public class MainEventHandler extends ChannelInboundHandlerAdapter { @Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws Exception { - Log.warning(formatChannel(ctx.channel()) + " error", cause.getCause()); + Log.warning(formatChannel(ctx.channel()) + " error", cause); closeChannel(ctx.channel()); } |