bugGNU Wget - Bugs: bug #45274, -nc option may delete HTML-files


bug #45274: -nc option may delete HTML-files

Submitter:  None
Submitted:  Mon 08 Jun 2015 12:04:37 PM UTC
Category:  Program Logic Severity:  3 - Normal
Priority:  5 - Normal Status:  None
Privacy:  Public Assigned to:  None
Originator Name:  Mike Originator Email:  -email is unavailable-
Open/Closed:  Open Release:  1.16.2
Operating System:  GNU/Linux Reproducibility:  Every Time
Fixed Release:  None Planned Release:  None
Regression:  None Work Required:  None
Patch Included:  None
* Mandatory Fields

Add a New Comment Rich Markup

Mon 08 Jun 2015 12:04:37 PM UTC, original submission:  

The documentation implies to some degree that the -nc option will never touch existing files. So I tried to get new images on a site using:

wget -r -N -A "*.html" http://site.com/
wget -r -nc -A "*.jpg" http://site.com/

The second invocation reads all html files from disk and deletes them afterwords. This is surprising. A workaround could be to figure out all extensions used for html-files on the site and add them to the -A option.

I think -nc should be changed to take precedence over other options like -A. This change will probably not break any existing script, since deleting files can be had much easier.



(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by None (Submitted the item)

    No changes have been made to this item

    Back to the top

    Powered by Savane 3.13-12ab.
    Corresponding source code