From 19063333ad586dba76029e3de7a88670ff9a5cb1 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Tue, 19 Sep 2006 14:18:18 +0000 Subject: [PATCH] Display an error when we come to the root. 2006-09-19 Matthias Clasen * gtk/gtkfilechooserdefault.c (update_current_folder_get_info_cb): Display an error when we come to the root. --- ChangeLog | 5 +++++ gtk/gtkfilechooserdefault.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 4b486d2206..9171dd076e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2006-09-19 Matthias Clasen + + * gtk/gtkfilechooserdefault.c (update_current_folder_get_info_cb): + Display an error when we come to the root. + 2006-09-16 Matthias Clasen * gtk/gtkfilechooserbutton.c: Use bookmark labels in diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c index e580f894dc..c5338b9b69 100644 --- a/gtk/gtkfilechooserdefault.c +++ b/gtk/gtkfilechooserdefault.c @@ -6174,7 +6174,8 @@ update_current_folder_get_info_cb (GtkFileSystemHandle *handle, } /* get parent path and try to change the folder to that */ - if (gtk_file_system_get_parent (impl->file_system, data->path, &parent_path, NULL)) + if (gtk_file_system_get_parent (impl->file_system, data->path, &parent_path, NULL) && + parent_path != NULL) { gtk_file_path_free (data->path); data->path = parent_path;