#11754 closed Bug (fixed)
Infinite loop in google chrome when contents contains not closed attributes
Reported by: | Josep Sanz | Owned by: | Marek Lewandowski |
---|---|---|---|
Priority: | Normal | Milestone: | CKEditor 4.4.1 |
Component: | General | Version: | 4.3.4 |
Keywords: | Cc: |
Description
When I edit some contents using Google Chrome, CKEditor enters into an infinite loop.
I have checked the problem with the latest release 4.3.4 and with the nighly's demo. I'm using Google Chrome in GNU/Linux, but some users report to me the same problem using Google Chrome in Microsoft Windows 7.
To reproduce the problem:
1) Go to http://ckeditor.com/demo
2) Click to the Source HTML button
3) Paste the follow html code:
<table border=0 cellspacing=0 cellpadding=0 style='border-collapse:collapse;></table>
4) Return to the default view mode (clicking to the Source HTML button)
And then, the browser is consuming all CPU into an infinite loop!!!
Change History (13)
comment:1 Changed 11 years ago by
Keywords: | chrome infinite loop removed |
---|---|
Milestone: | → CKEditor 4.4.1 |
Status: | new → confirmed |
Version: | 4.3.4 |
comment:4 Changed 11 years ago by
I did bisect that, issue is present since git:6675efbb79a4afd02ee7b2d52fefb2c07facd331
comment:5 Changed 11 years ago by
Version: | → 4.3.4 |
---|
comment:6 Changed 11 years ago by
Owner: | set to Marek Lewandowski |
---|---|
Status: | confirmed → assigned |
comment:7 Changed 11 years ago by
Status: | assigned → review |
---|
Pushed to t/11754 at dev and t/11754 at tests.
comment:8 Changed 11 years ago by
OMG...
- return data.replace( /<\w([^'">]+|'[^']*'|"[^"]*")+>/g, function( match ) { + return data.replace( /<\w+(?:\s+(?:(?:[^\s=>]+\s*=\s*(?:[^'"\s>]+|'[^']*'|"[^"]*"))|[^\s=>]+))+\s*>/g, function( match ) {
:D
comment:9 Changed 11 years ago by
Status: | review → review_passed |
---|
Force pushed some small corrections. Remember about leaving useful docs in both - dev code and tests. And there's nothing more useful in cases like this than tickets numbers.
While testing I found that Chrome and Firefox are not even trying to fix this missing quote - entire following code is parsed as style's attribute content. It's a definitely positive thing that browsers stop trying to be too smart.
comment:10 Changed 11 years ago by
Resolution: | → fixed |
---|---|
Status: | review_passed → closed |
Fixed with git:dc7bcdb232 (merged to master) at dev and 09d164903a (merged to master) at tests.
comment:11 Changed 11 years ago by
Is this bug fixed in 4.4.0 version? On demo page http://ckeditor.com/demo it still hangs Chrome tab with code:
<table border=0 cellspacing=0 cellpadding=0 style='border-collapse:collapse;></table>
CK version 4.4.0
comment:12 Changed 11 years ago by
This bug is already fixed on master and it will be fixed in 4.4.1 which will be released on 20th of May. 4.4.0 was released few weeks ago, so it cannot contain this patch.
Confirmed. Thanks.