From: Kornel Benko Date: Sat, 2 Jan 2016 10:29:11 +0000 (+0100) Subject: Cmake URL tests: Interpret 'Error 404' in received data as error. X-Git-Tag: 2.2.0beta1~274 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=4b49a59e71e1f117dbbaeb82a1083406045128d9;p=features.git Cmake URL tests: Interpret 'Error 404' in received data as error. --- diff --git a/development/checkurls/CheckURL.pm b/development/checkurls/CheckURL.pm index 8403c5dac3..2601e954fa 100755 --- a/development/checkurls/CheckURL.pm +++ b/development/checkurls/CheckURL.pm @@ -70,9 +70,14 @@ sub check_http_url($$$$) my $buf; my $n = $s->read_entity_body($buf, 1024); if (! defined($n)) { - print " Read from \"$protocol://$host$getp\" failed"; + print " Read from \"$protocol://$host$getp\" "; return 3; } + if ($buf =~ /\Error 404\<\/title\>/) { + print " Page reports 'Error 404' from \"$protocol://$host$getp\" "; + return 3; + } + return 0; } # Returns ($err, $isdir)