summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhalex <halex@openbsd.org>2009-06-04 23:37:09 +0000
committerhalex <halex@openbsd.org>2009-06-04 23:37:09 +0000
commit627d0b40af36ce91cfd5848bdca6c5314897275f (patch)
tree0f0a81f02d819b9a9e1ce4717262c59cd7f579b8
parentPrint a better message than '(null)' if no command is specified ("tmux \;"). (diff)
downloadwireguard-openbsd-627d0b40af36ce91cfd5848bdca6c5314897275f.tar.xz
wireguard-openbsd-627d0b40af36ce91cfd5848bdca6c5314897275f.zip
silently ignore -a if a username is supplied in the url
"looks sensible" deraadt@, "fine by me" martynas@ also removed an indeed misplaced/outdated comment per martynas@ request
-rw-r--r--usr.bin/ftp/fetch.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.bin/ftp/fetch.c b/usr.bin/ftp/fetch.c
index be548efe7b1..a8000fbad87 100644
--- a/usr.bin/ftp/fetch.c
+++ b/usr.bin/ftp/fetch.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: fetch.c,v 1.88 2009/06/04 20:58:34 martynas Exp $ */
+/* $OpenBSD: fetch.c,v 1.89 2009/06/04 23:37:09 halex Exp $ */
/* $NetBSD: fetch.c,v 1.14 1997/08/18 10:20:20 lukem Exp $ */
/*-
@@ -1010,9 +1010,11 @@ bad_ftp_url:
}
oautologin = autologin;
if (username == NULL)
- anonftp = 1; /* Handle "automatic" transfers. */
- else
+ anonftp = 1;
+ else {
+ anonftp = 0;
autologin = 0;
+ }
setpeer(xargc, xargv);
autologin = oautologin;
if (connected == 0 ||