From 4fab113d4eb1a03f41e35616bb00d2db0927b53a Mon Sep 17 00:00:00 2001 From: Sertonix Date: Sat, 29 Jun 2024 19:36:25 +0000 Subject: [PATCH] mk-ca-bundle.pl: delay 'curl -V' execution until it is needed Avoid an `Can't exec "curl"` message when curl is not actually needed. Closes #14060 --- scripts/mk-ca-bundle.pl | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/scripts/mk-ca-bundle.pl b/scripts/mk-ca-bundle.pl index 83027a4893..097171059b 100755 --- a/scripts/mk-ca-bundle.pl +++ b/scripts/mk-ca-bundle.pl @@ -136,8 +136,6 @@ else { $url = $opt_d; } -my $curl = `curl -V`; - if ($opt_i) { print ("=" x 78 . "\n"); print "Script Version : $version\n"; @@ -314,6 +312,7 @@ if(!$opt_n) { # If we have an HTTPS URL then use curl if($url =~ /^https:\/\//i) { + my $curl = `curl -V`; if($curl) { if($curl =~ /^Protocols:.* https( |$)/m) { report "Get certdata with curl!"; -- 2.47.3