notmuch-restore: fix error message for extra positional parameter.
authorDavid Bremner <bremner@debian.org>
Thu, 15 Nov 2012 02:42:39 +0000 (22:42 -0400)
committerDavid Bremner <bremner@debian.org>
Thu, 15 Nov 2012 22:20:10 +0000 (18:20 -0400)
Note that a single positional parameter will take this code path also,
so the old message really makes no sense anymore.

notmuch-restore.c

index 09dd6918e8d45ab5ff1696d4f08c5975dbf4f74b..7d8f44c4d7e856a43aab854a57f8c2d0ff623774 100644 (file)
@@ -145,8 +145,8 @@ notmuch_restore_command (unused (void *ctx), int argc, char *argv[])
 
     if (opt_index < argc) {
        fprintf (stderr,
-        "Cannot read dump from more than one file: %s\n",
-                argv[optind]);
+        "Unused positional parameter: %s\n",
+                argv[opt_index]);
        return 1;
     }