ribbons / RadioDownloader

An easy to use application for managing podcast subscriptions and downloads.
https://nerdoftheherd.com/tools/radiodld/
GNU General Public License v3.0
15 stars 11 forks source link

Linux: Fixed audio files failing to play if they have the execute permission set #237

Closed ribbons closed 4 years ago

ribbons commented 4 years ago

On Linux, if the downloaded programmes storage location doesn't preserve file permissions (such as a SMB mount) but instead gives every file 0777 (e.g. rwx for everyone), pressing the 'Play' button or double-clicking on a downloaded programme does not result in the download being played (but no error is shown).

After investigation, this appears to be caused by the Mono implementation of Process.Open - when a file has the execute bit set, Mono attempts to execute it and regards this as successful even though it couldn't be executed.

Interestingly, the dotnet core implementation has a comment and code which handles this exact scenario.