From b7420336470bd22d23543850441b3a7b6814c469 Mon Sep 17 00:00:00 2001 From: denise Date: Mon, 18 Jun 2012 12:24:13 -0400 Subject: [PATCH] - Add Media: fix to accept audio files with ID3 tags liquidsoap complains about --- airtime_mvc/application/models/StoredFile.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/airtime_mvc/application/models/StoredFile.php b/airtime_mvc/application/models/StoredFile.php index 3dd72ff4b..4e37a2bad 100644 --- a/airtime_mvc/application/models/StoredFile.php +++ b/airtime_mvc/application/models/StoredFile.php @@ -888,7 +888,7 @@ Logging::log("getting media! - 2"); // Check if file is playable $command = sprintf("/usr/bin/airtime-liquidsoap -c 'output.dummy(audio_to_stereo(single(\"%s\")))' 2>&1", $audio_file); exec($command, $output, $rv); - if ($rv != 0 || count($output) != 0) { + if ($rv != 0 || $output[0] == 'TagLib: MPEG::Properties::read() -- Could not find a valid last MPEG frame in the stream.') { $result = array("code" => 110, "message" => "This file appears to be corrupted and will not be added to media library."); } else {