diff options
author | Daniel Stenberg <daniel@haxx.se> | 2024-01-29 22:39:33 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2024-01-30 08:24:32 +0100 |
commit | 3e57bc2a84887eb96b0f47ccbe39aa5624192b8b (patch) | |
tree | b3c8953a1092546a2f0916d3240ce0584bffd896 | |
parent | 011325ff29638bfaa498c1a930950437c4e7dd62 (diff) | |
download | curl-3e57bc2a84887eb96b0f47ccbe39aa5624192b8b.tar.gz |
cd2nroff: fix duplicate output issue
Assisted-by: Jay Satiro
Fixes https://github.com/curl/curl-www/issues/321
Closes #12818
-rwxr-xr-x | scripts/cd2nroff | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/scripts/cd2nroff b/scripts/cd2nroff index bbc7969a3..e8c8235dd 100755 --- a/scripts/cd2nroff +++ b/scripts/cd2nroff @@ -337,14 +337,12 @@ sub single { 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 { |