diff --git a/airtime_mvc/application/models/StoredFile.php b/airtime_mvc/application/models/StoredFile.php index d699b47d1..b09421aca 100644 --- a/airtime_mvc/application/models/StoredFile.php +++ b/airtime_mvc/application/models/StoredFile.php @@ -879,6 +879,11 @@ Logging::log("getting media! - 2"); $audio_stor = Application_Common_OsPath::join($stor, "organize", $fileName); Logging::log("copyFileToStor: moving file $audio_file to $audio_stor"); + + if (chmod($audio_file, 0644) === false){ + Logging::log("Warning: couldn't change permissions of $audio_file to 0644"); + } + //Martin K.: changed to rename: Much less load + quicker since this is an atomic operation $r = @rename($audio_file, $audio_stor);