validator/httpd/cgi-bin check,1.689,1.690

Update of /sources/public/validator/httpd/cgi-bin
In directory hutz:/tmp/cvs-serv13094/httpd/cgi-bin

Modified Files:
	check 
Log Message:
Warn about tidy errors, keep tidy checkbox state with valid documents.

Index: check
===================================================================
RCS file: /sources/public/validator/httpd/cgi-bin/check,v
retrieving revision 1.689
retrieving revision 1.690
diff -u -d -r1.689 -r1.690
--- check	12 Sep 2009 14:49:28 -0000	1.689
+++ check	12 Sep 2009 15:57:50 -0000	1.690
@@ -1223,16 +1223,12 @@
     $cleaned = Encode::decode_utf8($cleaned);
     $File->{Tidy} = $cleaned;
   };
-  $File->{Tidy_OK} = !$@;
-}
-else {
-  # if document is valid, we don't really need tidy, do we?
-  $File->{Tidy_OK} = FALSE;
+  if ($@) {
+    (my $errmsg = $@) =~ s/ at .*//s;
+    &add_warning('W29', { W29_msg => $errmsg });
+  }
 }
 
-# if tidy not available, disable
-$File->{Opt}->{'Show Tidy'} &&= $File->{Tidy_OK};
-
 my $template;
 
 if ($File->{Opt}->{Output} eq 'xml') {

Received on Saturday, 12 September 2009 15:58:01 UTC