[Webkit-unassigned] [Bug 14636] New: broken tags with unpaired quote prevents encode autodetection

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jul 17 03:00:44 PDT 2007


http://bugs.webkit.org/show_bug.cgi?id=14636

           Summary: broken tags with unpaired quote prevents encode
                    autodetection
           Product: WebKit
           Version: 522+ (nightly)
          Platform: All
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Minor
          Priority: P4
         Component: Page Loading
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: 808caaa4.8ce9.9cd6c799e9f6 at gmail.com


// derived from bugs#14601

With some broken meta tags like:

> <meta http-equiv="Content-Type" content="text/html; charset="utf-8">

detectJapaneseEncoding() seems to not to be called.

For not-collectly-paired \x22, checkForHeadCharset() lost sync for quote and
runs out whole the content absorbed with returns-false
(at 'if(ptr == pEnd) return false;' line 588).

Tag/content may not contain linefeeds with almost websites.
I think successfully aborting at scanning quote pair
when linefeed occuered is with reality.

My experimental code.
-----
while (ptr != pEnd && *ptr != quoteMark)
{
        if(*ptr=='\r' || *ptr=='\n'){
                // too long tag content : may lost sync
                // successfully bail out
                m_checkedForHeadCharset = true;
                return true;
        }
++ptr;
}
-----


-- 
Configure bugmail: http://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list