Author: benny Date: 2007-01-08 22:22:18 +0000 (Mon, 08 Jan 2007) New Revision: 24325
Modified: thunar/trunk/ChangeLog thunar/trunk/thunar-vfs/thunar-vfs-io-local.c Log: 2007-01-08 Benedikt Meurer <[EMAIL PROTECTED]> * thunar-vfs/thunar-vfs-io-local.c(_thunar_vfs_io_local_listdir): Change back to the previous working directory after listing the directory contents. Modified: thunar/trunk/ChangeLog =================================================================== --- thunar/trunk/ChangeLog 2007-01-08 21:16:41 UTC (rev 24324) +++ thunar/trunk/ChangeLog 2007-01-08 22:22:18 UTC (rev 24325) @@ -1,5 +1,11 @@ 2007-01-08 Benedikt Meurer <[EMAIL PROTECTED]> + * thunar-vfs/thunar-vfs-io-local.c(_thunar_vfs_io_local_listdir): + Change back to the previous working directory after listing the + directory contents. + +2007-01-08 Benedikt Meurer <[EMAIL PROTECTED]> + * thunar/thunar-shortcuts-view.c(thunar_shortcuts_view_init): Ellipsize long shortcut names, but make sure "File System" still fits into the side pane. Modified: thunar/trunk/thunar-vfs/thunar-vfs-io-local.c =================================================================== --- thunar/trunk/thunar-vfs/thunar-vfs-io-local.c 2007-01-08 21:16:41 UTC (rev 24324) +++ thunar/trunk/thunar-vfs/thunar-vfs-io-local.c 2007-01-08 22:22:18 UTC (rev 24325) @@ -1,6 +1,6 @@ /* $Id$ */ /*- - * Copyright (c) 2005-2006 Benedikt Meurer <[EMAIL PROTECTED]> + * Copyright (c) 2005-2007 Benedikt Meurer <[EMAIL PROTECTED]> * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public @@ -623,6 +623,7 @@ GThreadPool *pool; gboolean failure = FALSE; gchar absolute_path[THUNAR_VFS_PATH_MAXSTRLEN]; + gchar *current_dir; GList *list; GList *lp; GList *ln; @@ -644,6 +645,9 @@ /* acquire the chdir lock */ G_LOCK (_thunar_vfs_io_local_chdir); + /* remember the current working directory */ + current_dir = g_get_current_dir (); + /* change to the desired directory */ if (chdir (absolute_path) < 0) { @@ -673,11 +677,8 @@ /* join the additional threads */ g_thread_pool_free (pool, FALSE, TRUE); - /* change back to the root folder (so we don't - * prevent the folder from being deleted on - * certain well-known file systems) - */ - chdir ("/"); + /* change back to the previous working directory */ + chdir (current_dir); } /* release the chdir lock */ @@ -707,6 +708,9 @@ } } + /* cleanup */ + g_free (current_dir); + return list; } _______________________________________________ Xfce4-commits mailing list Xfce4-commits@xfce.org http://foo-projects.org/mailman/listinfo/xfce4-commits