summaryrefslogtreecommitdiff
path: root/ftpfs
diff options
context:
space:
mode:
authorAlfred M. Szmidt <ams@gnu.org>2005-06-18 17:18:13 +0000
committerAlfred M. Szmidt <ams@gnu.org>2005-06-18 17:18:13 +0000
commitddeb9733fb4eccc2dc8bd36633db7b34a7ba3627 (patch)
tree02cee6969b96b34abff6e305436289f23d2e2daf /ftpfs
parente0dc9e1e71bf0a8ea96f517dc8f5dbf05aca2b94 (diff)
2005-06-14 Hugues Larrive <hugues.larrive@gmail.com>
* ftpfs.c (parse_startup_opt): User names may contain a @, so take the last @ of FTPFS_REMOTE_FS. * host.c (split_server_name): User names may contain a @, so take the last @ of P.
Diffstat (limited to 'ftpfs')
-rw-r--r--ftpfs/ChangeLog7
-rw-r--r--ftpfs/ftpfs.c2
-rw-r--r--ftpfs/host.c2
3 files changed, 9 insertions, 2 deletions
diff --git a/ftpfs/ChangeLog b/ftpfs/ChangeLog
index b53da74f..4f042123 100644
--- a/ftpfs/ChangeLog
+++ b/ftpfs/ChangeLog
@@ -1,3 +1,10 @@
+2005-06-14 Hugues Larrive <hugues.larrive@gmail.com>
+
+ * ftpfs.c (parse_startup_opt): User names may contain a @, so take
+ the last @ of FTPFS_REMOTE_FS.
+ * host.c (split_server_name): User names may contain a @, so take
+ the last @ of P.
+
2003-08-17 Marcus Brinkmann <marcus@gnu.org>
* ftpfs.h: Include <hurd/ihash.h>.
diff --git a/ftpfs/ftpfs.c b/ftpfs/ftpfs.c
index 492df79e..09c072d1 100644
--- a/ftpfs/ftpfs.c
+++ b/ftpfs/ftpfs.c
@@ -255,7 +255,7 @@ parse_startup_opt (int key, char *arg, struct argp_state *state)
{
int h_err; /* Host lookup error. */
error_t err;
- char *sep = strchr (ftpfs_remote_fs, '@');
+ char *sep = strrchr (ftpfs_remote_fs, '@');
if (sep)
/* FTPFS_REMOTE_FS includes a '@', which means that it's in
diff --git a/ftpfs/host.c b/ftpfs/host.c
index a0703afe..cd6fd4c0 100644
--- a/ftpfs/host.c
+++ b/ftpfs/host.c
@@ -38,7 +38,7 @@ split_server_name (const char *server, char **host, char **user, char **passwd)
/* Extract the hostname; syntax is either `HOST:...', `...@HOST', or just
HOST if there are no user parameters specified. */
- sep = strchr (p, '@');
+ sep = strrchr (p, '@');
if (sep)
/* ...@HOST */
{