From: Marcel Raad Date: Mon, 30 Sep 2019 22:32:26 +0000 (+0200) Subject: checksrc: fix uninitialized variable warning X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ac830139dadf4abd48232e3eb5ce0c8d06d19dcf;p=curl checksrc: fix uninitialized variable warning The loop doesn't need to be executed without a file argument. Closes https://github.com/curl/curl/pull/4444 --- diff --git a/lib/checksrc.pl b/lib/checksrc.pl index 965f0bab1..b2cfa8355 100755 --- a/lib/checksrc.pl +++ b/lib/checksrc.pl @@ -176,7 +176,7 @@ sub checkwarn { $file = shift @ARGV; -while(1) { +while(defined $file) { if($file =~ /-D(.*)/) { $dir = $1;