From 21036a2efce1253a62ec9aadba520afbe2a98527 Mon Sep 17 00:00:00 2001 From: "Brett T. Warden" Date: Tue, 8 Jun 2021 10:06:52 -0700 Subject: [PATCH] Check whether proxies are necessary with --full If --full is specified, even if URL checks succeeded, check whether they'll succeed *without* a proxy configured. Also check HTTPS_PROXY, as curl allows upper case for all but http_proxy. --- configure.ac | 2 +- scripts/clr-network-troubleshooter.in | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/configure.ac b/configure.ac index 2633571..bd4e871 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ([2.69]) -AC_INIT([clr-network-troubleshooter],[14]) +AC_INIT([clr-network-troubleshooter],[15]) AM_INIT_AUTOMAKE # Checks for programs. diff --git a/scripts/clr-network-troubleshooter.in b/scripts/clr-network-troubleshooter.in index bc0b065..5131129 100755 --- a/scripts/clr-network-troubleshooter.in +++ b/scripts/clr-network-troubleshooter.in @@ -444,7 +444,7 @@ sub check_proxies_reachable { } } - foreach my $proxy_var (qw(http_proxy https_proxy)) { + foreach my $proxy_var (qw(http_proxy https_proxy HTTPS_PROXY)) { if (my $proxy = $ENV{${proxy_var}}) { my $failed; my $command = "curl --connect-timeout 10 -s --proxy '' -L ${proxy}"; @@ -488,9 +488,9 @@ sub check_proxies_reachable { sub check_proxies_necessary { # Check whether proxies are actually necessary to reach the test URLs - !$main_version_check && check_download_clearlinux_org(''); - !$mirror_version_check && check_mirror(''); - !$plain_http_check && check_plain_http_site(''); + ($OPT_FULL || !$main_version_check) && check_download_clearlinux_org(''); + ($OPT_FULL || !$mirror_version_check) && check_mirror(''); + ($OPT_FULL || !$plain_http_check) && check_plain_http_site(''); } sub set_network_date {