I have several local ics calendar files that are marked as read-only on file system level. Using menu File > Open > Calendar File to subscribe to them as a new calendar doesn't work anymore. I only get a Windows error message that the file is read-only and I need to choose a different file. Fails using Lightning 1.4a1 + Thunderbird 12.0a1 Fails using Lightning 1.3a2 + Thunderbird 11.0a2 Works using Lightning 1.2b2 + Thunderbird 10.0
Seems to be a toolkit issue and can be reproduce using Firefox too. Steps to Reproduce using Firefox: 1. Create file on local harddisc and mark it as read-only, e.g. a html webpage file. 2. In Firefox use menu File > Open File... and select the file Actual result: An error dialog stating that the file is read-only and a different file should be selected. Expected result: File is opened and the content is displayed. Works in Firefox 10. Fails in Firefox 11.
Hmm, not able to reproduce. I created the file as an admin, created a new standard user account, and marked the file for read-only access for that user. Then opened the file with the File->open dialog under the test account. Didn't have any problems. I will experiment some more. Maybe there is something unique set up that I might be missing?
Testing the regression range might help - those patches landed 2011-12-14, so they would be in the 12-15 build: http://ftp.mozilla.org/pub/mozilla.org/firefox/nightly/ The zips of these builds make this pretty easy to test if you have some spare time Stefan.
I think I can see the potential cause though - http://mxr.mozilla.org/mozilla-central/source/widget/windows/nsFilePicker.cpp#896 FOS_NOREADONLYRETURN should only be applied if mMode == modeSave.
In fact, it's the default value - FOS_NOREADONLYRETURN - Do not return read-only items. This is a default value for the Save dialog. patch coming up.
Created attachment 589286 [details] [diff] [review] patch
Created attachment 589298 [details] [diff] [review] patch minor update on this - there's a mode case statement further down I can use.
Comment on attachment 589298 [details] [diff] [review] patch Review of attachment 589298 [details] [diff] [review]: ----------------------------------------------------------------- Looks good. Tested and everything is working correctly. Tested on XP and it works consistent with the new functionality in this patch.
Regression range: Works in 11.0a1 (BuildID: 20111214031134) Fails in 11.0a1 (BuildID: 20111215031153) https://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=fd6ab19f312c&tochange=beac16509534 I'm not aware of anything special regarding setup. Windows 7 with NTFS file system. Same standard user is used to create the file, mark it read-only via context menu > properties > attributes, and running Firefox (fresh profile).
https://hg.mozilla.org/integration/mozilla-inbound/rev/0e424ab9ddff Let's get this into a nightly and test to see if it addresses the problem. My guess is it will.
Comment on attachment 589298 [details] [diff] [review] patch Another file pickers fix, the new file pickers code is in aurora so we need to get this in too. Low risk.
Verified fixed using Mozilla/5.0 (Windows NT 6.1; rv:12.0a1) Gecko/20120120 Firefox/12.0a1.
Comment on attachment 589298 [details] [diff] [review] patch [Triage Comment] New file picker in 11, needed on Aurora.
Verified as fixed on: Mozilla/5.0 (Windows NT 6.1; rv:11.0) Gecko/20100101 Firefox/11.0 Read-only files are selected and opened without any issues. Thunderbird could not be tested since there is no Lightning version compatible with 11b1.