aboutsummaryrefslogtreecommitdiff
path: root/src/org/traccar/Server.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2012-12-18 22:31:16 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2012-12-18 22:31:16 +1300
commitf72eade8742022502e69b300296c8ac1fbf35b25 (patch)
tree4ae108a169b51dbb36e2789f367dac77310ccbc3 /src/org/traccar/Server.java
parent34923934e0ee7d707aa9ffef2712942115236472 (diff)
downloadtrackermap-server-f72eade8742022502e69b300296c8ac1fbf35b25.tar.gz
trackermap-server-f72eade8742022502e69b300296c8ac1fbf35b25.tar.bz2
trackermap-server-f72eade8742022502e69b300296c8ac1fbf35b25.zip
Couple of small changes
Diffstat (limited to 'src/org/traccar/Server.java')
-rw-r--r--src/org/traccar/Server.java9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/org/traccar/Server.java b/src/org/traccar/Server.java
index 506513b60..2167a7933 100644
--- a/src/org/traccar/Server.java
+++ b/src/org/traccar/Server.java
@@ -28,8 +28,10 @@ import java.util.List;
import java.util.Properties;
import java.util.logging.FileHandler;
import java.util.logging.Formatter;
+import java.util.logging.Handler;
import java.util.logging.Level;
import java.util.logging.LogRecord;
+import java.util.logging.Logger;
import org.jboss.netty.bootstrap.ServerBootstrap;
import org.jboss.netty.buffer.ChannelBuffers;
import org.jboss.netty.channel.ChannelPipeline;
@@ -200,7 +202,12 @@ public class Server {
}
});
- // NOTE: Console logger level will remain INFO
+ // Remove old logging handlers
+ Handler[] handlers = Logger.getLogger("").getHandlers();
+ for(Handler handler : handlers) {
+ Logger.getLogger("").removeHandler(handler);
+ }
+
Log.getLogger().setLevel(Level.ALL);
Log.getLogger().addHandler(file);
}