diff options
author | Vladimir Dronnikov <dronnikov@gmail.com> | 2009-10-05 02:18:01 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2009-10-05 02:18:01 +0200 |
commit | be168b119750beacc0d0212607c6fa3ee87f238c (patch) | |
tree | 95240a7661366674fd9cdf2741e8ab1bfe823ba5 /networking/wget.c | |
parent | 301f5ecb8d5fc1ed85942dd85d58f27a0c9a518a (diff) | |
download | busybox-w32-be168b119750beacc0d0212607c6fa3ee87f238c.tar.gz busybox-w32-be168b119750beacc0d0212607c6fa3ee87f238c.tar.bz2 busybox-w32-be168b119750beacc0d0212607c6fa3ee87f238c.zip |
wget: fix for code 302; mount: support -o union
Signed-off-by: Vladimir Dronnikov <dronnikov@gmail.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/wget.c')
-rw-r--r-- | networking/wget.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/networking/wget.c b/networking/wget.c index b8cd54964..0f99e8d13 100644 --- a/networking/wget.c +++ b/networking/wget.c | |||
@@ -370,8 +370,10 @@ static void parse_url(char *src_url, struct host_info *h) | |||
370 | h->path = sp; | 370 | h->path = sp; |
371 | } | 371 | } |
372 | 372 | ||
373 | // We used to set h->user to NULL here, but this interferes | ||
374 | // with handling of code 302 ("object was moved") | ||
375 | |||
373 | sp = strrchr(h->host, '@'); | 376 | sp = strrchr(h->host, '@'); |
374 | h->user = NULL; | ||
375 | if (sp != NULL) { | 377 | if (sp != NULL) { |
376 | h->user = h->host; | 378 | h->user = h->host; |
377 | *sp = '\0'; | 379 | *sp = '\0'; |
@@ -692,6 +694,7 @@ int wget_main(int argc UNUSED_PARAM, char **argv) | |||
692 | 694 | ||
693 | /* TODO: compat issue: should handle "wget URL1 URL2..." */ | 695 | /* TODO: compat issue: should handle "wget URL1 URL2..." */ |
694 | 696 | ||
697 | target.user = NULL; | ||
695 | parse_url(argv[optind], &target); | 698 | parse_url(argv[optind], &target); |
696 | 699 | ||
697 | /* Use the proxy if necessary */ | 700 | /* Use the proxy if necessary */ |