After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 753969 - check if a folder is accessible
check if a folder is accessible
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: GtkFileChooser
3.17.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
Federico Mena Quintero
Depends on:
Blocks:
 
 
Reported: 2015-08-22 16:25 UTC by Paolo Borelli
Modified: 2015-08-23 20:46 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (3.51 KB, patch)
2015-08-22 16:27 UTC, Paolo Borelli
accepted-commit_now Details | Review

Description Paolo Borelli 2015-08-22 16:25:20 UTC
When saving, if the user enters /root/file.txt we show the replace confirmation dialog. Instead we should see that /root/ is not accessible at all and present an error to the user.

This came up in relation to https://bugzilla.gnome.org/show_bug.cgi?id=753932

Btw, I can also submit a gtk patch move the check to see if the file is readonly instead of having it custom in gedit
Comment 1 Paolo Borelli 2015-08-22 16:27:00 UTC
Created attachment 309868 [details] [review]
patch

Note: if you test with gedit, you will need to rebuild it since I committed a related patch there
Comment 2 Paolo Borelli 2015-08-22 16:50:33 UTC
A couple of notes:
 - the patch is only lightly tested at the moment (I just checked the case of bug 753932)
 - I assumed that the "access::can-execute" has the same semantic of the "x" bit in unix for directroy... I am not sure if that is the case or if that breaks on windows and remote file systems
Comment 3 Matthias Clasen 2015-08-22 17:10:06 UTC
Review of attachment 309868 [details] [review]:

Works well enough for me, thanks!

If you commit this, please announce the string addition
Comment 4 Paolo Borelli 2015-08-23 13:59:05 UTC
We checked with LRN and it seems we are ok on Windows.

I pushed the patch and sent the string change mail.


I'll file another bug for the patch porting the read-only check from gedit