From 52f10c9fa7b7c36b7a15107a3422248805f0320b Mon Sep 17 00:00:00 2001 From: 0xb00bface <0xboobface@gmail.com> Date: Fri, 1 Jan 2021 20:33:47 +0100 Subject: [PATCH] Catch AssertionError in AccuratePlaylistGenerator --- .../main/java/ctbrec/recorder/AccuratePlaylistGenerator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/src/main/java/ctbrec/recorder/AccuratePlaylistGenerator.java b/common/src/main/java/ctbrec/recorder/AccuratePlaylistGenerator.java index 2fc0a86f..73abfed2 100644 --- a/common/src/main/java/ctbrec/recorder/AccuratePlaylistGenerator.java +++ b/common/src/main/java/ctbrec/recorder/AccuratePlaylistGenerator.java @@ -55,7 +55,7 @@ public class AccuratePlaylistGenerator extends PlaylistGenerator { .withUri(file.getName()) .withTrackInfo(new TrackInfo(duration, file.getName())) .build()); - } catch (Exception e) { + } catch (Exception | AssertionError e) { LOG.warn("Couldn't determine duration for {}. Skipping this file.", file.getName()); File corruptedFile = new File(directory, file.getName() + ".corrupt"); Files.move(file, corruptedFile);