]> sjero.net Git - wget/commitdiff
If -nc and -k are used at the same time, use only the latter
authorGiuseppe Scrivano <gscrivano@gnu.org>
Thu, 9 Dec 2010 12:27:17 +0000 (13:27 +0100)
committerGiuseppe Scrivano <gscrivano@gnu.org>
Thu, 9 Dec 2010 12:27:17 +0000 (13:27 +0100)
src/ChangeLog
src/main.c

index c2e2220c9ffd0055e394d8286af288ab9271e5b8..994f8957d95661ed1abd6cd1b413d8aeab964ee6 100644 (file)
@@ -1,3 +1,9 @@
+2010-12-09  Giuseppe Scrivano  <gscrivano@gnu.org>
+
+       * main.c (main): If --no-clobber and --convert-links are used at the
+       same time, use only the latter.
+       Reported by: Romain Vimont <rom@rom1v.com>
+
 2010-12-07  Jessica McKellar <jesstess@mit.edu> (tiny change)
 
        * main.c: Make help message clearer.
index ce0b58f6e305aa5ff7ae17692efeec3a32894896..a583bac4cf771bc2b5756abf9bf5fad60abc78f5 100644 (file)
@@ -1060,6 +1060,14 @@ main (int argc, char **argv)
   /* All user options have now been processed, so it's now safe to do
      interoption dependency checks. */
 
+  if (opt.noclobber && opt.convert_links)
+    {
+      fprintf (stderr,
+               _("Both --no-clobber and --convert-links were specified,"
+                 "only --convert-links will be used.\n"));
+      opt.noclobber = false;
+    }
+
   if (opt.reclevel == 0)
       opt.reclevel = INFINITE_RECURSION; /* see recur.h for commentary */