mirror of
https://github.com/moparisthebest/wget
synced 2024-07-03 16:38:41 -04:00
[svn] Fixed -k when using -O.
This commit is contained in:
parent
14645396e2
commit
65af6f7432
@ -1,3 +1,8 @@
|
||||
2004-11-18 Hans-Andreas Engel <engel@node.ch>
|
||||
|
||||
* http.c: Enable --convert-links (-k) when a single page is downloaded
|
||||
via --output-document (-O).
|
||||
|
||||
2004-11-18 Mauro Tortonesi <mauro@deepspace6.net>
|
||||
|
||||
* connect.c: Minor correction to the comment in front of fd_peek.
|
||||
|
@ -1801,7 +1801,7 @@ http_loop (struct url *u, char **newloc, char **local_file, const char *referer,
|
||||
/* Determine the local filename. */
|
||||
if (local_file && *local_file)
|
||||
hstat.local_file = local_file;
|
||||
else if (local_file)
|
||||
else if (local_file && !opt.output_document)
|
||||
{
|
||||
*local_file = url_file_name (u);
|
||||
hstat.local_file = local_file;
|
||||
@ -1810,6 +1810,9 @@ http_loop (struct url *u, char **newloc, char **local_file, const char *referer,
|
||||
{
|
||||
dummy = url_file_name (u);
|
||||
hstat.local_file = &dummy;
|
||||
/* be honest about where we will save the file */
|
||||
if (local_file && opt.output_document)
|
||||
*local_file = HYPHENP (opt.output_document) ? NULL : xstrdup (opt.output_document);
|
||||
}
|
||||
|
||||
if (!opt.output_document)
|
||||
@ -1962,8 +1965,6 @@ File `%s' already there, will not retrieve.\n"), *hstat.local_file);
|
||||
*hstat.local_file to tack on ".html". */
|
||||
if (!opt.output_document)
|
||||
locf = *hstat.local_file;
|
||||
else
|
||||
locf = opt.output_document;
|
||||
|
||||
/* Time? */
|
||||
tms = time_str (NULL);
|
||||
|
Loading…
Reference in New Issue
Block a user