[html5] r5764 - [cgiowt] (1) Make the charset sniffer more accurately match the parser. Fixing h [...]
whatwg at whatwg.org
whatwg at whatwg.org
Mon Jan 10 22:03:33 PST 2011
Author: ianh
Date: 2011-01-10 22:03:32 -0800 (Mon, 10 Jan 2011)
New Revision: 5764
Modified:
complete.html
index
source
Log:
[cgiowt] (1) Make the charset sniffer more accurately match the parser.
Fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=11411
Modified: complete.html
===================================================================
--- complete.html 2011-01-11 05:22:35 UTC (rev 5763)
+++ complete.html 2011-01-11 06:03:32 UTC (rev 5764)
@@ -76505,7 +76505,7 @@
<li><p>Let <var title="">got pragma</var> be false.</li>
- <li><p>Let <var title="">mode</var> be null.</li>
+ <li><p>Let <var title="">need pragma</var> be null.</li>
<li><p>Let <var title="">charset</var> be the null value
(which, for the purposes of this algorithm, is distinct from
@@ -76518,6 +76518,9 @@
<li><p>If the attribute's name is already in <var title="">attribute list</var>, then return to the step
labeled <i>attributes</i>.</p>
+ <li><p>Add the attribute's name to <var title="">attribute
+ list</var>.</p>
+
<li>
<p>Run the appropriate step from the following list, if one
@@ -76528,29 +76531,28 @@
<dd><p>If the attribute's value is "<code title="">content-type</code>", then set <var title="">got
pragma</var> to true.</dd>
- <dt>If the attribute's name is "<code title="">charset</code>"</dt>
-
- <dd><p>If <var title="">charset</var> is still set to null,
- let <var title="">charset</var> be the encoding
- corresponding to the attribute's value, and set <var title="">mode</var> to "charset".</dd>
-
<dt>If the attribute's name is "<code title="">content</code>"</dt>
<dd><p>Apply the <a href=#algorithm-for-extracting-an-encoding-from-a-content-type>algorithm for extracting an encoding
from a Content-Type</a>, giving the attribute's value as
the string to parse. If an encoding is returned, and if
<var title="">charset</var> is still set to null, let <var title="">charset</var> be the encoding returned, and set
- <var title="">mode</var> to "pragma".</dd>
+ <var title="">need pragma</var> to true.</dd>
+ <dt>If the attribute's name is "<code title="">charset</code>"</dt>
+
+ <dd><p>Let <var title="">charset</var> be the encoding
+ corresponding to the attribute's value, and set <var title="">need pragma</var> to false.</dd>
+
</dl></li>
<li><p>Return to the step labeled <i>attributes</i>.</li>
- <li><p><i>Processing</i>: If <var title="">mode</var> is
- null, then jump to the second step of the overall "two step"
- algorithm.</li>
+ <li><p><i>Processing</i>: If <var title="">need pragma</var>
+ is null, then jump to the second step of the overall "two
+ step" algorithm.</li>
- <li><p>If <var title="">mode</var> is "pragma" but <var title="">got pragma</var> is false, then jump to the second
+ <li><p>If <var title="">mode</var> is true but <var title="">got pragma</var> is false, then jump to the second
step of the overall "two step" algorithm.</li>
<li><p>If <var title="">charset</var> is a UTF-16 encoding,
Modified: index
===================================================================
--- index 2011-01-11 05:22:35 UTC (rev 5763)
+++ index 2011-01-11 06:03:32 UTC (rev 5764)
@@ -72479,7 +72479,7 @@
<li><p>Let <var title="">got pragma</var> be false.</li>
- <li><p>Let <var title="">mode</var> be null.</li>
+ <li><p>Let <var title="">need pragma</var> be null.</li>
<li><p>Let <var title="">charset</var> be the null value
(which, for the purposes of this algorithm, is distinct from
@@ -72492,6 +72492,9 @@
<li><p>If the attribute's name is already in <var title="">attribute list</var>, then return to the step
labeled <i>attributes</i>.</p>
+ <li><p>Add the attribute's name to <var title="">attribute
+ list</var>.</p>
+
<li>
<p>Run the appropriate step from the following list, if one
@@ -72502,29 +72505,28 @@
<dd><p>If the attribute's value is "<code title="">content-type</code>", then set <var title="">got
pragma</var> to true.</dd>
- <dt>If the attribute's name is "<code title="">charset</code>"</dt>
-
- <dd><p>If <var title="">charset</var> is still set to null,
- let <var title="">charset</var> be the encoding
- corresponding to the attribute's value, and set <var title="">mode</var> to "charset".</dd>
-
<dt>If the attribute's name is "<code title="">content</code>"</dt>
<dd><p>Apply the <a href=#algorithm-for-extracting-an-encoding-from-a-content-type>algorithm for extracting an encoding
from a Content-Type</a>, giving the attribute's value as
the string to parse. If an encoding is returned, and if
<var title="">charset</var> is still set to null, let <var title="">charset</var> be the encoding returned, and set
- <var title="">mode</var> to "pragma".</dd>
+ <var title="">need pragma</var> to true.</dd>
+ <dt>If the attribute's name is "<code title="">charset</code>"</dt>
+
+ <dd><p>Let <var title="">charset</var> be the encoding
+ corresponding to the attribute's value, and set <var title="">need pragma</var> to false.</dd>
+
</dl></li>
<li><p>Return to the step labeled <i>attributes</i>.</li>
- <li><p><i>Processing</i>: If <var title="">mode</var> is
- null, then jump to the second step of the overall "two step"
- algorithm.</li>
+ <li><p><i>Processing</i>: If <var title="">need pragma</var>
+ is null, then jump to the second step of the overall "two
+ step" algorithm.</li>
- <li><p>If <var title="">mode</var> is "pragma" but <var title="">got pragma</var> is false, then jump to the second
+ <li><p>If <var title="">mode</var> is true but <var title="">got pragma</var> is false, then jump to the second
step of the overall "two step" algorithm.</li>
<li><p>If <var title="">charset</var> is a UTF-16 encoding,
Modified: source
===================================================================
--- source 2011-01-11 05:22:35 UTC (rev 5763)
+++ source 2011-01-11 06:03:32 UTC (rev 5764)
@@ -86597,7 +86597,7 @@
<li><p>Let <var title="">got pragma</var> be false.</p></li>
- <li><p>Let <var title="">mode</var> be null.</p></li>
+ <li><p>Let <var title="">need pragma</var> be null.</p></li>
<li><p>Let <var title="">charset</var> be the null value
(which, for the purposes of this algorithm, is distinct from
@@ -86612,6 +86612,9 @@
title="">attribute list</var>, then return to the step
labeled <i>attributes</i>.</p>
+ <li><p>Add the attribute's name to <var title="">attribute
+ list</var>.</p>
+
<li>
<p>Run the appropriate step from the following list, if one
@@ -86627,14 +86630,6 @@
pragma</var> to true.</p></dd>
<dt>If the attribute's name is "<code
- title="">charset</code>"</dt>
-
- <dd><p>If <var title="">charset</var> is still set to null,
- let <var title="">charset</var> be the encoding
- corresponding to the attribute's value, and set <var
- title="">mode</var> to "charset".</p></dd>
-
- <dt>If the attribute's name is "<code
title="">content</code>"</dt>
<dd><p>Apply the <span>algorithm for extracting an encoding
@@ -86642,19 +86637,26 @@
the string to parse. If an encoding is returned, and if
<var title="">charset</var> is still set to null, let <var
title="">charset</var> be the encoding returned, and set
- <var title="">mode</var> to "pragma".</p></dd>
+ <var title="">need pragma</var> to true.</p></dd>
+ <dt>If the attribute's name is "<code
+ title="">charset</code>"</dt>
+
+ <dd><p>Let <var title="">charset</var> be the encoding
+ corresponding to the attribute's value, and set <var
+ title="">need pragma</var> to false.</p></dd>
+
</dl>
</li>
<li><p>Return to the step labeled <i>attributes</i>.</p></li>
- <li><p><i>Processing</i>: If <var title="">mode</var> is
- null, then jump to the second step of the overall "two step"
- algorithm.</p></li>
+ <li><p><i>Processing</i>: If <var title="">need pragma</var>
+ is null, then jump to the second step of the overall "two
+ step" algorithm.</p></li>
- <li><p>If <var title="">mode</var> is "pragma" but <var
+ <li><p>If <var title="">mode</var> is true but <var
title="">got pragma</var> is false, then jump to the second
step of the overall "two step" algorithm.</p></li>
More information about the Commit-Watchers
mailing list