Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ruffle doesn't recognise file permissions on macOS #10889

Open
Korne127 opened this issue Apr 30, 2023 · 0 comments
Open

Ruffle doesn't recognise file permissions on macOS #10889

Korne127 opened this issue Apr 30, 2023 · 0 comments
Labels
macos Issues related to MacOS

Comments

@Korne127
Copy link
Contributor

How it's supposed to be:
When you start an SWF with the command line, the NavigatorBackend::fetch method gets invoked and tries to read the file. If it doesn't have the necessary permissions to read the file, a fallback is used which asks the user to click open in a file dialogue to get the permissions.
If Ruffle already has the necessary permissions, it shouldn't need to do that and directly be able to open the file.

What happens instead:
When you start an SWF on macOS with the shell, you always get this fallback and file dialogue where you need to click open.
Even if you manually give Ruffle full disk access in the system preferences, Ruffle still gets the PermissionDenied error and needs to use the fallback to be able to read the file.
This happens independently to whether you use open ./Ruffle.app --args file.swf or ./Ruffle.app/Contents/MacOS/ruffle file.swf to open the SWF file.

Other notes:
It's not easy to debug this since the self-compiled version always has the permissions to read files; therefore this bug doesn't occur with it.
It also might make more sense to ask for permanent permissions to read that file since this fallback causes you to click through two windows (the explain window and the file dialogue) every time you start an SWF (even without this bug), and you'd need to manually give Ruffle disk access in the settings to stop this. Therefore, it would probably be better if Ruffle asked for being given the read permissions so it doesn't need to ask again every single time when starting an SWF. (You could also do both, ask for read permissions and if denied, still using the current fallback.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
macos Issues related to MacOS
Projects
None yet
Development

No branches or pull requests

2 participants