Skip to content

Commit

Permalink
[c] (0) Change the limit for where charsets should be given to the fi…
Browse files Browse the repository at this point in the history
…rst 1024 bytes.

Fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=11426

git-svn-id: http://svn.whatwg.org/webapps@5860 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Feb 9, 2011
1 parent 1a3a8cc commit 51babfe
Show file tree
Hide file tree
Showing 3 changed files with 73 additions and 39 deletions.
37 changes: 24 additions & 13 deletions complete.html
Expand Up @@ -14253,9 +14253,10 @@ <h5 id=charset><span class=secno>4.2.5.5 </span>Specifying the document's charac
the use of <a href=#syntax-charref title=syntax-charref>character references</a>
or character escapes of any kind.</li>

<li id=charset512>The element containing the character encoding
declaration must be serialized completely within the first 512
bytes of the document.</li>
<li id=charset1024><span id=charset512 title="">The element
containing the character encoding declaration must be serialized
completely within the first 1024 bytes of the document.</span></li>
<!-- span is for historical reasons, to keep an old ID alive -->

<li>There can only be one character encoding declaration in the
document.</li> <!-- conformance criteria for this one are given in
Expand Down Expand Up @@ -76963,16 +76964,26 @@ <h5 id=determining-the-character-encoding><span class=secno>12.2.2.1 </span>Dete
supported, return that encoding with the <a href=#concept-encoding-confidence title=concept-encoding-confidence>confidence</a>
<i>certain</i>, and abort these steps.</li>

<li><p>The user agent may wait for more bytes of the resource to be
available, either in this step or at any later step in this
algorithm. For instance, a user agent might wait 500ms or 512
bytes, whichever came first. In general preparsing the source to
find the encoding improves performance, as it reduces the need to
throw away the data structures used when parsing upon finding the
encoding information. However, if the user agent delays too long to
obtain data to determine the encoding, then the cost of the delay
could outweigh any performance improvements from the
preparse.</li>
<li>

<p>The user agent may wait for more bytes of the resource to be
available, either in this step or at any later step in this
algorithm. For instance, a user agent might wait 500ms or 1024
bytes, whichever came first. In general preparsing the source to
find the encoding improves performance, as it reduces the need to
throw away the data structures used when parsing upon finding the
encoding information. However, if the user agent delays too long
to obtain data to determine the encoding, then the cost of the
delay could outweigh any performance improvements from the
preparse.</p>

<p class=note>The authoring conformance requirements for
character encoding declarations limit them to only appearing <a href=#charset1024>in the first 1024 bytes</a>. User agents are
therefore encouraged to use the preparse algorithm below (part of
these steps) on the first 1024 bytes, but not to stall beyond
that.</p>

</li>

<li><p>For each of the rows in the following table, starting with
the first one and going down, if there are as many or more bytes
Expand Down
37 changes: 24 additions & 13 deletions index
Expand Up @@ -14233,9 +14233,10 @@ people expect to have work and what is necessary.
the use of <a href=#syntax-charref title=syntax-charref>character references</a>
or character escapes of any kind.</li>

<li id=charset512>The element containing the character encoding
declaration must be serialized completely within the first 512
bytes of the document.</li>
<li id=charset1024><span id=charset512 title="">The element
containing the character encoding declaration must be serialized
completely within the first 1024 bytes of the document.</span></li>
<!-- span is for historical reasons, to keep an old ID alive -->

<li>There can only be one character encoding declaration in the
document.</li> <!-- conformance criteria for this one are given in
Expand Down Expand Up @@ -72934,16 +72935,26 @@ interface <dfn id=messageport>MessagePort</dfn> {
supported, return that encoding with the <a href=#concept-encoding-confidence title=concept-encoding-confidence>confidence</a>
<i>certain</i>, and abort these steps.</li>

<li><p>The user agent may wait for more bytes of the resource to be
available, either in this step or at any later step in this
algorithm. For instance, a user agent might wait 500ms or 512
bytes, whichever came first. In general preparsing the source to
find the encoding improves performance, as it reduces the need to
throw away the data structures used when parsing upon finding the
encoding information. However, if the user agent delays too long to
obtain data to determine the encoding, then the cost of the delay
could outweigh any performance improvements from the
preparse.</li>
<li>

<p>The user agent may wait for more bytes of the resource to be
available, either in this step or at any later step in this
algorithm. For instance, a user agent might wait 500ms or 1024
bytes, whichever came first. In general preparsing the source to
find the encoding improves performance, as it reduces the need to
throw away the data structures used when parsing upon finding the
encoding information. However, if the user agent delays too long
to obtain data to determine the encoding, then the cost of the
delay could outweigh any performance improvements from the
preparse.</p>

<p class=note>The authoring conformance requirements for
character encoding declarations limit them to only appearing <a href=#charset1024>in the first 1024 bytes</a>. User agents are
therefore encouraged to use the preparse algorithm below (part of
these steps) on the first 1024 bytes, but not to stall beyond
that.</p>

</li>

<li><p>For each of the rows in the following table, starting with
the first one and going down, if there are as many or more bytes
Expand Down
38 changes: 25 additions & 13 deletions source
Expand Up @@ -15061,9 +15061,10 @@ people expect to have work and what is necessary.
the use of <span title="syntax-charref">character references</span>
or character escapes of any kind.</li>

<li id="charset512">The element containing the character encoding
declaration must be serialized completely within the first 512
bytes of the document.</li>
<li id="charset1024"><span title="" id="charset512">The element
containing the character encoding declaration must be serialized
completely within the first 1024 bytes of the document.</span></li>
<!-- span is for historical reasons, to keep an old ID alive -->

<li>There can only be one character encoding declaration in the
document.</li> <!-- conformance criteria for this one are given in
Expand Down Expand Up @@ -87094,16 +87095,27 @@ interface <span>WindowLocalStorage</span> {
title="concept-encoding-confidence">confidence</span>
<i>certain</i>, and abort these steps.</p></li>

<li><p>The user agent may wait for more bytes of the resource to be
available, either in this step or at any later step in this
algorithm. For instance, a user agent might wait 500ms or 512
bytes, whichever came first. In general preparsing the source to
find the encoding improves performance, as it reduces the need to
throw away the data structures used when parsing upon finding the
encoding information. However, if the user agent delays too long to
obtain data to determine the encoding, then the cost of the delay
could outweigh any performance improvements from the
preparse.</p></li>
<li>

<p>The user agent may wait for more bytes of the resource to be
available, either in this step or at any later step in this
algorithm. For instance, a user agent might wait 500ms or 1024
bytes, whichever came first. In general preparsing the source to
find the encoding improves performance, as it reduces the need to
throw away the data structures used when parsing upon finding the
encoding information. However, if the user agent delays too long
to obtain data to determine the encoding, then the cost of the
delay could outweigh any performance improvements from the
preparse.</p>

<p class="note">The authoring conformance requirements for
character encoding declarations limit them to only appearing <a
href="#charset1024">in the first 1024 bytes</a>. User agents are
therefore encouraged to use the preparse algorithm below (part of
these steps) on the first 1024 bytes, but not to stall beyond
that.</p>

</li>

<li><p>For each of the rows in the following table, starting with
the first one and going down, if there are as many or more bytes
Expand Down

0 comments on commit 51babfe

Please sign in to comment.