[webkit-changes] cvs commit: WebCore/khtml/html htmltokenizer.cpp
Darin
darin at opensource.apple.com
Sat Sep 10 14:33:19 PDT 2005
darin 05/09/10 14:33:18
Modified: . ChangeLog
khtml/html htmltokenizer.cpp
Log:
Reviewed and landed by Darin.
- fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=4820
hexadecimal HTML entities split across TCP packets are not parsed correctly
Wasn't able to make a layout test for this because there's no easy way to
simulate separate writes to the tokenizer.
* khtml/html/htmltokenizer.cpp: (khtml::HTMLTokenizer::parseEntity):
Rolled back to code more like the original KDE stuff -- our change broke this --
but changed the limit so it works with 8-character entities.
Revision Changes Path
1.114 +14 -0 WebCore/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /cvs/root/WebCore/ChangeLog,v
retrieving revision 1.113
retrieving revision 1.114
diff -u -r1.113 -r1.114
--- ChangeLog 10 Sep 2005 21:22:36 -0000 1.113
+++ ChangeLog 10 Sep 2005 21:33:16 -0000 1.114
@@ -1,3 +1,17 @@
+2005-09-10 Alexey Proskuryakov <ap at nypop.com>
+
+ Reviewed and landed by Darin.
+
+ - fixed http://bugzilla.opendarwin.org/show_bug.cgi?id=4820
+ hexadecimal HTML entities split across TCP packets are not parsed correctly
+
+ Wasn't able to make a layout test for this because there's no easy way to
+ simulate separate writes to the tokenizer.
+
+ * khtml/html/htmltokenizer.cpp: (khtml::HTMLTokenizer::parseEntity):
+ Rolled back to code more like the original KDE stuff -- our change broke this --
+ but changed the limit so it works with 8-character entities.
+
2005-09-10 Darin Adler <darin at apple.com>
- remove test case I just added -- it's not working
1.110 +3 -2 WebCore/khtml/html/htmltokenizer.cpp
Index: htmltokenizer.cpp
===================================================================
RCS file: /cvs/root/WebCore/khtml/html/htmltokenizer.cpp,v
retrieving revision 1.109
retrieving revision 1.110
diff -u -r1.109 -r1.110
--- htmltokenizer.cpp 27 Aug 2005 00:12:33 -0000 1.109
+++ htmltokenizer.cpp 10 Sep 2005 21:33:18 -0000 1.110
@@ -763,19 +763,20 @@
case Hexadecimal:
{
- int ll = kMin(src.length(), 8U);
+ int ll = kMin(src.length(), 10-cBufferPos);
while(ll--) {
QChar csrc(src->lower());
cc = csrc.cell();
if(csrc.row() || !((cc >= '0' && cc <= '9') || (cc >= 'a' && cc <= 'f'))) {
+ Entity = SearchSemicolon;
break;
}
EntityUnicodeValue = EntityUnicodeValue*16 + (cc - ( cc < 'a' ? '0' : 'a' - 10));
cBuffer[cBufferPos++] = cc;
++src;
}
- Entity = SearchSemicolon;
+ if(cBufferPos == 10) Entity = SearchSemicolon;
break;
}
case Decimal:
More information about the webkit-changes
mailing list