[CSS] using :first-letter with floating elements locks mozilla

RESOLVED WORKSFORME

Status

()

P2
critical
RESOLVED WORKSFORME
17 years ago
15 years ago

People

(Reporter: pascalc, Unassigned)

Tracking

({hang, testcase})

Trunk
Future
hang, testcase
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

17 years ago
1 go to the testcase I will put in attachment
2 [details] [diff] [review] put your mouse over the text

Expected result: all the <span> elements inside <h2></h2> should become block
elements floating on the left and the first letter of the <h2> title should
become red.

Actual result: Mozilla gets locked and unresponsive with 99% CPU use and I have
to kill the task

Here is the code of the page :

<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

<html xml:lang="fr">
<head>
<title>test</title>

<style type="text/css">
div.bloc:hover > h2 span { display:block; float:left}
div.bloc > h2:first-letter {color:red;}
</style>
	
</head>

<body>
<div class="bloc">
<h2>
<span>vendredi</span>
<span>06</span>
<span>septembre</span>
<span>2002</span>
</h2>
</div>
</body>
</html>
->Layout
Assignee: dbaron → attinasi
Component: Style System → Layout
QA Contact: ian → petersen
(Reporter)

Comment 2

17 years ago
Created attachment 98219 [details]
Testcase  making Mozilla being locked with 99% CPU use

If you delete float:left, Mozilla no longer gets locked.
The infinite loop is in:

#0  nsCSSFrameConstructor::RemoveFloatingFirstLetterFrames (this=0x87c6d90, 
    aPresContext=0x888c700, aPresShell=0x888f930, aFrameManager=0x888ffa8, 
    aBlockFrame=0x88a5d8c, aStopLooking=0xbfffe570)
    at /builds/trunk/mozilla/layout/html/style/src/nsCSSFrameConstructor.cpp:12994
#1  0x41c69285 in nsCSSFrameConstructor::RemoveLetterFrames (this=0x87c6d90, 
    aPresContext=0x888c700, aPresShell=0x888f930, aFrameManager=0x888ffa8, 
    aBlockFrame=0x88a5d8c)
    at /builds/trunk/mozilla/layout/html/style/src/nsCSSFrameConstructor.cpp:13181
#2  0x41c5ede7 in nsCSSFrameConstructor::ContentRemoved (this=0x87c6d90, 
    aPresContext=0x888c700, aContainer=0x88a7e20, aChild=0x88a7f78, 
    aIndexInContainer=5, aInContentReplaced=0)
    at /builds/trunk/mozilla/layout/html/style/src/nsCSSFrameConstructor.cpp:9726
...

because |floater| is its own next sibling, so the loop over next siblings never
terminates.
(Reporter)

Comment 4

17 years ago
I forgot to tell about my configuration :
Windows Xp Athlon 1700XP 256 MB Ram
Build 2002090415, the problem also affects NS7

Comment 5

17 years ago
this regressed between linux trunk builds 2002041008 and 2002041108
and 1.0 branch builds 20020421 and 20020430
look like bug 5693
Severity: critical → major
Hardware: All → PC

Updated

17 years ago
QA Contact: petersen → amar

Updated

17 years ago
Priority: -- → P2
Target Milestone: --- → Future

Comment 6

17 years ago
oops
Severity: major → critical
Hardware: PC → All

Updated

16 years ago
Keywords: testcase

Comment 7

16 years ago
==> floats
Assignee: attinasi → float
Component: Layout → Layout: Floats
QA Contact: amar → ian

Comment 8

16 years ago
Reproduced on 12/21/02 Trunk build, Linux.

Comment 9

16 years ago
I just reproduced the problem with this test case on a pc with win98 and
Mozilla/5.0 (Windows; U; Win98; en-US; rv:1.3b) Gecko/20030210. I was looking to
see if there was bug that has been already reported. Thnis problem has not shown
up in earlier builds for me than the one I just loaded. I've used builds from 1,
1.1, 1.1a, 1.1b, 1.2.1, 1.2b, 1.3a.

I get simular results on
http://www.weather.com/weather/climatology/monthly/USFL0372
sorta like bug 177574 but I see the contents before locking

http://moonfeyrie.homestead.com/linkmusic.html
mine. With both of these pages I can run the scroll bar around a while before 
it locks up.
(Reporter)

Comment 10

16 years ago
FYI, problem is still there with build 2003060908
This is fixed?
WFM Mozilla 1.6a
This bug worksforme with Windows Seamonkey builds 2004020909
Status: NEW → RESOLVED
Last Resolved: 15 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.