gvfs r2272 - in trunk: . daemon
- From: alexl svn gnome org
- To: svn-commits-list gnome org
- Subject: gvfs r2272 - in trunk: . daemon
- Date: Mon, 2 Mar 2009 12:16:28 +0000 (UTC)
Author: alexl
Date: Mon Mar 2 12:16:28 2009
New Revision: 2272
URL: http://svn.gnome.org/viewvc/gvfs?rev=2272&view=rev
Log:
2009-03-02 Alexander Larsson <alexl redhat com>
Bug 550929 â nautilus sftp:// doesn't read User in ~/.ssh/config
* daemon/gvfsbackendsftp.c:
Don't specify user unless requested explicitly by the uri.
Patch from Christian Neumair
Modified:
trunk/ChangeLog
trunk/daemon/gvfsbackendsftp.c
Modified: trunk/daemon/gvfsbackendsftp.c
==============================================================================
--- trunk/daemon/gvfsbackendsftp.c (original)
+++ trunk/daemon/gvfsbackendsftp.c Mon Mar 2 12:16:28 2009
@@ -365,8 +365,11 @@
}
- args[last_arg++] = g_strdup ("-l");
- args[last_arg++] = g_strdup (op_backend->user);
+ if (op_backend->user_specified)
+ {
+ args[last_arg++] = g_strdup ("-l");
+ args[last_arg++] = g_strdup (op_backend->user);
+ }
args[last_arg++] = g_strdup ("-s");
@@ -885,10 +888,14 @@
else
password_in_keyring = TRUE;
- if (new_user && strcmp (new_user, op_backend->user) != 0)
+ if (new_user &&
+ (op_backend->user == NULL ||
+ strcmp (new_user, op_backend->user) != 0))
{
g_free (op_backend->user);
op_backend->user = new_user;
+
+ op_backend->user_specified = TRUE;
g_free (op_backend->tmp_password);
op_backend->tmp_password = new_password;
@@ -1584,8 +1591,6 @@
op_backend->user = g_strdup (user);
if (op_backend->user)
op_backend->user_specified = TRUE;
- else
- op_backend->user = g_strdup (g_get_user_name ());
return FALSE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]