Skip to content

Commit

Permalink
[e] (0) Define 'overlong form'.
Browse files Browse the repository at this point in the history
Fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=11369

git-svn-id: http://svn.whatwg.org/webapps@5733 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Jan 1, 2011
1 parent 102b979 commit e253b59
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 5 deletions.
9 changes: 7 additions & 2 deletions complete.html
Expand Up @@ -3604,7 +3604,7 @@ <h3 id=utf-8><span class=secno>2.4 </span>UTF-8</h3>

<dl class=switch><dt>One byte in the range FE to FF</dt>

<dt>Overlong forms (e.g. F0 80 80 A0)</dt>
<dt><a href=#overlong-form title="overlong form">Overlong forms</a> (e.g. F0 80 80 A0)</dt>

<dt>One byte in the range C0 to C1, followed by one byte in the range 80 to BF</dt>

Expand Down Expand Up @@ -3638,7 +3638,12 @@ <h3 id=utf-8><span class=secno>2.4 </span>UTF-8</h3>

<dd>Each byte must be replaced with a U+FFFD REPLACEMENT CHARACTER.</dd>

</dl><p class=example>For example, the byte string "41 98 BA 42 E2 98
</dl><p>For the purposes of the above requirements, an <dfn id=overlong-form>overlong
form</dfn> in UTF-8 is a sequence that encodes a codepoint using
more bytes than the minimum needed to encode that codepoint in
UTF-8.</p>

<p class=example>For example, the byte string "41 98 BA 42 E2 98
43 E2 98 BA E2 98" would be converted to the string
"A&#65533;&#65533;B&#65533;C&#9786;&#65533;".</p>

Expand Down
9 changes: 7 additions & 2 deletions index
Expand Up @@ -3583,7 +3583,7 @@ a.setAttribute('href', 'http://example.com/'); // change the content attribute d

<dl class=switch><dt>One byte in the range FE to FF</dt>

<dt>Overlong forms (e.g. F0 80 80 A0)</dt>
<dt><a href=#overlong-form title="overlong form">Overlong forms</a> (e.g. F0 80 80 A0)</dt>

<dt>One byte in the range C0 to C1, followed by one byte in the range 80 to BF</dt>

Expand Down Expand Up @@ -3617,7 +3617,12 @@ a.setAttribute('href', 'http://example.com/'); // change the content attribute d

<dd>Each byte must be replaced with a U+FFFD REPLACEMENT CHARACTER.</dd>

</dl><p class=example>For example, the byte string "41 98 BA 42 E2 98
</dl><p>For the purposes of the above requirements, an <dfn id=overlong-form>overlong
form</dfn> in UTF-8 is a sequence that encodes a codepoint using
more bytes than the minimum needed to encode that codepoint in
UTF-8.</p>

<p class=example>For example, the byte string "41 98 BA 42 E2 98
43 E2 98 BA E2 98" would be converted to the string
"A&#65533;&#65533;B&#65533;C&#9786;&#65533;".</p>

Expand Down
7 changes: 6 additions & 1 deletion source
Expand Up @@ -2592,7 +2592,7 @@ a.setAttribute('href', 'http://example.com/'); // change the content attribute d

<dt>One byte in the range FE to FF</dt>

<dt>Overlong forms (e.g. F0 80 80 A0)</dt>
<dt><span title="overlong form">Overlong forms</span> (e.g. F0 80 80 A0)</dt>

<dt>One byte in the range C0 to C1, followed by one byte in the range 80 to BF</dt>

Expand Down Expand Up @@ -2628,6 +2628,11 @@ a.setAttribute('href', 'http://example.com/'); // change the content attribute d

</dl>

<p>For the purposes of the above requirements, an <dfn>overlong
form</dfn> in UTF-8 is a sequence that encodes a codepoint using
more bytes than the minimum needed to encode that codepoint in
UTF-8.</p>

<p class="example">For example, the byte string "41 98 BA 42 E2 98
43 E2 98 BA E2 98" would be converted to the string
"A&#xFFFD;&#xFFFD;B&#xFFFD;C&#x263A;&#xFFFD;".</p>
Expand Down

0 comments on commit e253b59

Please sign in to comment.