summaryrefslogtreecommitdiff
path: root/daemon
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2008-10-16 16:54:31 +0000
committerAlexander Larsson <alexl@src.gnome.org>2008-10-16 16:54:31 +0000
commitc2aa528c17d2d4ef9e236b41b0c26d641ea11d6b (patch)
tree179b4c411eaeceee6596a010ba50ba02ccc16ded /daemon
parentbf5f2f424ad33a4450ffd330eb40d6c9f054c57d (diff)
downloadgvfs-c2aa528c17d2d4ef9e236b41b0c26d641ea11d6b.tar.gz
Show username in auth dialog if specified in uri (#554156)
2008-10-16 Alexander Larsson <alexl@redhat.com> * daemon/gvfsbackendftp.c: (do_mount): Show username in auth dialog if specified in uri (#554156) 2008-10-16 Alexander Larsson <alexl@redhat.com> * client/gvfsfusedaemon.c (getattr_for_file): Set st_blocks & co so that du works (#554682) Patch from Andreas Henriksson svn path=/trunk/; revision=2052
Diffstat (limited to 'daemon')
-rw-r--r--daemon/gvfsbackendftp.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/daemon/gvfsbackendftp.c b/daemon/gvfsbackendftp.c
index fe4d02de..3a3d789e 100644
--- a/daemon/gvfsbackendftp.c
+++ b/daemon/gvfsbackendftp.c
@@ -1339,9 +1339,15 @@ do_mount (GVfsBackend *backend,
{
GAskPasswordFlags flags;
if (prompt == NULL)
- /* translators: %s here is the hostname */
- prompt = g_strdup_printf (_("Enter password for ftp on %s"), host);
-
+ {
+ if (ftp->has_initial_user)
+ /* Translators: the first %s is the username, the second the host name */
+ prompt = g_strdup_printf (_("Enter password for ftp as %s on %s"), ftp->user, host);
+ else
+ /* translators: %s here is the hostname */
+ prompt = g_strdup_printf (_("Enter password for ftp on %s"), host);
+ }
+
flags = G_ASK_PASSWORD_NEED_PASSWORD;
if (!ftp->has_initial_user)