Closed
Bug 279939
Opened 20 years ago
Closed 20 years ago
The plaintext serializer asserts and relies on unsigned integer overflow when dealing with raw <li>s
Categories
(Core :: DOM: Serializers, defect)
Core
DOM: Serializers
Tracking
()
RESOLVED
FIXED
People
(Reporter: mrbkap, Assigned: mrbkap)
References
()
Details
(Keywords: assertion)
Attachments
(1 file)
924 bytes,
patch
|
akkzilla
:
review+
jst
:
superreview+
|
Details | Diff | Splinter Review |
Steps to reproduce:
* Load the testcase in the URL (in a debug build)
* Click on the bullet to select that list item
* Right click on the selection to bring up a context menu (or just hit ctrl+c to
copy it)
* Notice that we assert "mULCount should be greater than 0 here".
This code still works becuase mULCount is a PRUint32 so (mULCount - 1) % 4 is
greater than 0 and less than 4. I have a patch that removes this assertion and
removes this dependance on mULCount being unsigned.
Assignee | ||
Comment 1•20 years ago
|
||
Note that the magical "3" value is there to preserve our behavior (use the same
letter for such cases).
Attachment #172474 -
Flags: superreview?(jst)
Attachment #172474 -
Flags: review?(akkzilla)
Comment 2•20 years ago
|
||
Comment on attachment 172474 [details] [diff] [review]
patch v1
sr=jst
Attachment #172474 -
Flags: superreview?(jst) → superreview+
Comment 3•20 years ago
|
||
Comment on attachment 172474 [details] [diff] [review]
patch v1
I wonder why that assumption was there? I suspect the intent was that the
serializer was supposed to see the context that included the ul, and increment
mULCount. Maybe that was from before we had content iterators. Anyway,
evidently it's not doing that now, and the new code is certainly better than
the crufty old code. r=akkana
Attachment #172474 -
Flags: review?(akkzilla) → review+
Assignee | ||
Comment 4•20 years ago
|
||
Fix checked in.
Status: NEW → RESOLVED
Closed: 20 years ago
Keywords: assertion
OS: Windows XP → All
Hardware: PC → All
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•