diff options
-rw-r--r-- | src/main.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c index a95dd100d..7913383e1 100644 --- a/src/main.c +++ b/src/main.c @@ -1579,7 +1579,9 @@ operate(struct Configurable *config, int argc, char *argv[]) /* multiple files extracted to stdout, insert separators! */ separator = 1; } - for (i = 0; (url = urls?next_url(urls):(i?NULL:url)); ++i) { + for(i = 0; + (url = urls?next_url(urls):(i?NULL:strdup(url))); + i++) { char *outfile; outfile = outfiles?strdup(outfiles):NULL; |