Improved handling of missing/failed transcoder

Fixes #659.

Signed-off-by: Andrew DeMaria <lostonamountain@gmail.com>
master
Evan Harris 5 years ago committed by Andrew DeMaria
parent 431b42bfb3
commit f644f5a1d0
No known key found for this signature in database
GPG Key ID: 0A3F5E91F8364EDF
  1. 4
      airsonic-main/src/main/java/org/airsonic/player/service/TranscodingService.java

@ -245,8 +245,10 @@ public class TranscodingService {
return createDownsampledInputStream(parameters); return createDownsampledInputStream(parameters);
} }
} catch (IOException x) {
LOG.warn("Transcoder failed: {}. Using original: " + parameters.getMediaFile().getFile().getAbsolutePath(), x.toString());
} catch (Exception x) { } catch (Exception x) {
LOG.warn("Failed to transcode " + parameters.getMediaFile() + ". Using original.", x); LOG.warn("Transcoder failed. Using original: " + parameters.getMediaFile().getFile().getAbsolutePath(), x);
} }
return new FileInputStream(parameters.getMediaFile().getFile()); return new FileInputStream(parameters.getMediaFile().getFile());

Loading…
Cancel
Save