Opened 14 years ago

Closed 11 years ago

#6340 closed Bug (fixed)

Google Chrome hangs when CKEditor parses malformed HTML

Reported by: Nicolás Cardelino Owned by:
Priority: Normal Milestone:
Component: General Version: 3.4.1
Keywords: Chrome Cc:

Description (last modified by Sa'ar Zac Elias)

Steps to reproduce:

  1. From Google Chrome open the CKEditor demo page (http://ckeditor.com/demo) and go to the Source view.
  2. Paste the following malformed HTML:
    <span id="sample" overflow="hidden" ;"="" style="font-size:8pt; font-weight:normal; font-style:normal; color:#808080; background:transparent">Text</span>
    
  3. Switch to WYSIWYG mode, so the HTML gets parsed.


After following these steps, the browser tab should hang.

CKEditor version: 3.4.1
Browser: Google Chrome 6.0.472.62 (Build oficial 59676)
OS: Ms Windows 7

I debugged the problem and found out that the problem is in this regular expression that is used to parse the HTML:

htmlPartsRegex:new RegExp("<(?:(?:\\/([^>]+)>)|(?:!--([\\S|\\s]*?)-->)|(?:([^\\s>]+)\\s*((?:(?:[^\"'>]+)|(?:\"[^\"]*\")|(?:'[^']*'))*)\\/?>))",'g')

Thanks in advance.

Change History (2)

comment:1 Changed 14 years ago by Sa'ar Zac Elias

Description: modified (diff)
Keywords: Chrome added
Status: newconfirmed

Works fine with Safari.

comment:2 Changed 11 years ago by Piotrek Koszuliński

Resolution: fixed
Status: confirmedclosed

Couldn't reproduce it in latest Chrome.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy