Bug 1900521 Comment 5 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

(In reply to :Gijs (he/him) from comment #4)
> Though it's worth noting that bug 1664646 sort of suggests that on Unix machines, testing for executable-ness isn't the right thing to do

I would definitely agree that it's not the right thing to do here - especially since we're setting the permissions on the dummy file ourselves to `0600`. We'll only find an executable bit if storing to a file system where permissions don't exist and are RWX for all files, which I think explains bug 1664646. Note that `nsLocalFile::IsExecutable` does more than just checking the executable bit [even in the nsLocalFileUnix.cpp implementation](https://searchfox.org/mozilla-central/source/xpcom/io/nsLocalFileUnix.cpp#1767-1871) - but I think checking the executable bit on the dummy file is only causing bug 1664646 without providing any benefit.
(In reply to :Gijs (he/him) from comment #4)
> Though it's worth noting that bug 1664646 sort of suggests that on Unix machines, testing for executable-ness isn't the right thing to do

I would definitely agree that it's not the right thing to do here - especially since we're setting the permissions on the dummy file ourselves to `0600`. I believe we'll only find an executable bit if storing to a file system where permissions don't exist and are RWX for all files, which I think could explain bug 1664646. Note that `nsLocalFile::IsExecutable` does more than just checking the executable bit [even in the nsLocalFileUnix.cpp implementation](https://searchfox.org/mozilla-central/source/xpcom/io/nsLocalFileUnix.cpp#1767-1871) - but I think checking the executable bit on the dummy file is only causing bug 1664646 without providing any benefit.

Back to Bug 1900521 Comment 5