From 070df25f4567e22ec138b26d0543b6779231c03f Mon Sep 17 00:00:00 2001 From: Bonome Date: Wed, 4 Apr 2018 17:39:44 +0200 Subject: [PATCH] catch exceptions ClientAbortException display a short message and return, to avoid the massive useless traceback in log Signed-off-by: Bonome --- .../org/airsonic/player/controller/StreamController.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/airsonic-main/src/main/java/org/airsonic/player/controller/StreamController.java b/airsonic-main/src/main/java/org/airsonic/player/controller/StreamController.java index 51b20919..d92f1478 100644 --- a/airsonic-main/src/main/java/org/airsonic/player/controller/StreamController.java +++ b/airsonic-main/src/main/java/org/airsonic/player/controller/StreamController.java @@ -29,6 +29,7 @@ import org.airsonic.player.service.sonos.SonosHelper; import org.airsonic.player.util.HttpRange; import org.airsonic.player.util.StringUtil; import org.airsonic.player.util.Util; +import org.apache.catalina.connector.ClientAbortException; import org.apache.commons.io.IOUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -248,7 +249,9 @@ public class StreamController { } } } - + } catch (ClientAbortException err) { + LOG.info("org.apache.catalina.connector.ClientAbortException: Connection reset"); + return; } finally { if (status != null) { securityService.updateUserByteCounts(user, status.getBytesTransfered(), 0L, 0L);