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 304565 - [Patch] gtk_file_chooser_remove_shortcut_folder_uri calls wrong method to convert uri
[Patch] gtk_file_chooser_remove_shortcut_folder_uri calls wrong method to con...
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Widget: Other
unspecified
Other Linux
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2005-05-17 18:39 UTC by Ismael Juma
Modified: 2005-05-18 21:01 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10


Attachments
One-liner that fixes the issue (485 bytes, patch)
2005-05-17 18:40 UTC, Ismael Juma
none Details | Review

Description Ismael Juma 2005-05-17 18:39:53 UTC
Version details: CVS Head
Distribution/Version: Fedora Core 4

1. Add a shortcut with gtk_file_chooser_add_shortcut_folder_uri.   
2. Remove the just added shortcut with   
gtk_file_chooser_remove_shortcut_folder_uri.   
   
Expected Result:   
Successful removal of shortcut.   
   
Actual Result:   
Shortcut is not found and therefore not removed.   
   
The problem seems to be the following line:   
path = gtk_file_system_filename_to_path (_gtk_file_chooser_get_file_system   
(chooser), uri);   
   
Changing it to the following solves the problem:   
path = gtk_file_system_uri_to_path (_gtk_file_chooser_get_file_system   
(chooser), uri);   
   
I'm attaching a patch that applies in HEAD. Thanks.
Comment 1 Ismael Juma 2005-05-17 18:40:51 UTC
Created attachment 46559 [details] [review]
One-liner that fixes the issue
Comment 2 Matthias Clasen 2005-05-18 21:01:53 UTC
2005-05-18  Matthias Clasen  <mclasen@redhat.com>

	* gtk/gtkfilechooser.c (gtk_file_chooser_remove_shortcut_folder_uri): 
	Use the correct function to conver the uri to a path.  (#304565,
	Ismael Juma)