[gnome-commander/gcmd-1-4] Removed gnome_cmd_dir_is_local, fixes bgo#731557



commit f7b3971858f006b21940039ef72bc85b18c59cee
Author: Uwe Scholz <uwescholz src gnome org>
Date:   Sun Jun 15 22:45:06 2014 +0200

    Removed gnome_cmd_dir_is_local, fixes bgo#731557

 src/gnome-cmd-xfer.cc |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/src/gnome-cmd-xfer.cc b/src/gnome-cmd-xfer.cc
index e6ce571..419a9d7 100644
--- a/src/gnome-cmd-xfer.cc
+++ b/src/gnome-cmd-xfer.cc
@@ -182,7 +182,9 @@ static gint async_xfer_callback (GnomeVFSAsyncHandle *handle, GnomeVFSXferProgre
 
     if (info->status == GNOME_VFS_XFER_PROGRESS_STATUS_OVERWRITE)
     {
-        gchar *s = gnome_cmd_dir_is_local (data->src_fl->cwd) ? gnome_vfs_get_local_path_from_uri 
(info->source_name) : str_uri_basename (info->source_name);
+       gchar *s = NULL;
+       // Check if the src uri is from local ('file:///...'). If not, just use the base name.
+       if ( !(s = gnome_vfs_get_local_path_from_uri (info->source_name) )) s = str_uri_basename 
(info->source_name);
         gchar *t = gnome_cmd_dir_is_local (data->to_dir) ? gnome_vfs_get_local_path_from_uri 
(info->target_name) : str_uri_basename (info->target_name);
 
         gchar *source_filename = get_utf8 (s);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]