| Summary: | [test case] attribute/> causes attribute to be dropped | ||
|---|---|---|---|
| Product: | [Applications] konqueror | Reporter: | Bugs Kde Org <bugs.kde.org> |
| Component: | khtml parsing | Assignee: | Konqueror Bugs <konqueror-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | agr, James.Seagraves |
| Priority: | NOR | ||
| Version First Reported In: | 3.2.2 | ||
| Target Milestone: | --- | ||
| Platform: | unspecified | ||
| OS: | Linux | ||
| Latest Commit: | Version Fixed/Implemented In: | ||
| Sentry Crash Report: | |||
|
Description
Bugs Kde Org
2004-08-14 23:18:47 UTC
Reference to the spec? I never heared of ISO-HTML before Use Google: http://www.cs.tcd.ie/15445/15445.HTML ISO-HTML is a standard, not a recommendation. validator.w3c.org can validate ISO-HTML. 2nd example comes us selected in mozilla 1.7.3 and unselected in kde 3.3.1. 1st example works fine. *** Bug 120347 has been marked as a duplicate of this bug. *** *** Bug 94630 has been marked as a duplicate of this bug. *** SVN commit 576632 by ggarand:
support parsing of attribute/>
not taking WC patch on this one has it looks a tad cheesy.
BUG: 87221
M +10 -5 htmltokenizer.cpp
--- branches/KDE/3.5/kdelibs/khtml/html/htmltokenizer.cpp #576631:576632
@@ -904,8 +904,16 @@
unsigned int a;
cBuffer[cBufferPos] = '\0';
a = khtml::getAttrID(cBuffer, cBufferPos);
- if ( !a )
- attrName = QString::fromLatin1(QCString(cBuffer, cBufferPos+1).data());
+ if ( !a ) {
+ // did we just get /> or e.g checked/>
+ if (curchar == '>' && cBufferPos >=1 && cBuffer[cBufferPos-1] == '/') {
+ currToken.flat = true;
+ if (cBufferPos>1)
+ a = khtml::getAttrID(cBuffer, cBufferPos-1);
+ }
+ if (!a)
+ attrName = QString::fromLatin1(QCString(cBuffer, cBufferPos+1).data());
+ }
dest = buffer;
*dest++ = a;
@@ -915,9 +923,6 @@
else
kdDebug( 6036 ) << "Known attribute: " << QCString(cBuffer, cBufferPos+1).data() << endl;
#endif
- // did we just get />
- if (!a && cBufferPos == 1 && *cBuffer == '/' && curchar == '>')
- currToken.flat = true;
tag = SearchEqual;
break;
|