commit | 3e57bc2a84887eb96b0f47ccbe39aa5624192b8b | [log] [tgz] |
---|---|---|
author | Daniel Stenberg <daniel@haxx.se> | Mon Jan 29 22:39:33 2024 +0100 |
committer | Daniel Stenberg <daniel@haxx.se> | Tue Jan 30 08:24:32 2024 +0100 |
tree | b3c8953a1092546a2f0916d3240ce0584bffd896 | |
parent | 011325ff29638bfaa498c1a930950437c4e7dd62 [diff] |
cd2nroff: fix duplicate output issue Assisted-by: Jay Satiro Fixes https://github.com/curl/curl-www/issues/321 Closes #12818
diff --git a/scripts/cd2nroff b/scripts/cd2nroff index bbc7969..e8c8235 100755 --- a/scripts/cd2nroff +++ b/scripts/cd2nroff
@@ -337,14 +337,12 @@ return $errors; } -$f = $ARGV[0]; -if(defined($f)) { - while($f) { - $r = single($f); +if(@ARGV) { + for my $f (@ARGV) { + my $r = single($f); if($r) { exit $r; } - $f = shift @ARGV; } } else {