markup-validator commit: Don't treat empty uri= as uri=1.

changeset:   3218:5397d1dc8889
tag:         tip
user:        Ville Skyttä <ville.skytta@iki.fi>
date:        Sun Mar 13 13:11:54 2011 +0200
files:       httpd/cgi-bin/check
description:
Don't treat empty uri= as uri=1.


diff -r ff04289cb4b8 -r 5397d1dc8889 httpd/cgi-bin/check
--- a/httpd/cgi-bin/check	Sun Mar 13 13:06:19 2011 +0200
+++ b/httpd/cgi-bin/check	Sun Mar 13 13:11:54 2011 +0200
@@ -2778,14 +2778,8 @@
         my @values = map { Encode::decode_utf8($_) } $q->param($param);
         $q->param($param, @values);
 
-        # Original checking had a specific Accept: header sent.
-        next if $param eq 'accept';
-
-        # Ditto Accept-Language:.
-        next if $param eq 'accept-language';
-
-        # Ditto Accept-Charset:.
-        next if $param eq 'accept-charset';
+        # Skip parameters that should not be treated as booleans.
+        next if $param =~ /^(?:accept(?:-(?:language|charset))?|ur[il])$/;
 
         # Keep false-but-set params.
         next if $q->param($param) eq '0';

Received on Sunday, 13 March 2011 11:12:08 UTC