Closed Bug 46782 Opened 24 years ago Closed 24 years ago

assertion in nsHTMLEditUtils::IsBreak()

Categories

(Core :: DOM: Editor, defect, P4)

defect

Tracking

()

VERIFIED FIXED

People

(Reporter: waterson, Assigned: mozeditor)

References

()

Details

(Whiteboard: [nsbeta3-][p:4][minus])

I hit an assertion in nsHTMLEditUtils::IsBreak() because this code: 

  http://lxr.mozilla.org/seamonkey/source/editor/base/nsHTMLEditRules.cpp#1228 

is passing in a null node for "maybeBreak". Should you handle the case 
where GetPriorHTMLSibling() returns a null node? 

I looked at GetPriorHTMLSibling(), and it seems to be valid to return a 
null node.

To reproduce:

1. Open composer on an empty document.
2. Hit a couple line feeds
3. Insert a horizontal rule
4. Return the cursor to the top of the document
5. Hit the "del" key to delete the carriage returns

You'll get the assertion as soon as you delete the last carriage return.
setting to m18, correctness and nsbeta3
Keywords: correctness, nsbeta3
Target Milestone: --- → M18
Added correctness and nsbeta3+
Whiteboard: [nsbeta3+]
setting priority in status whiteboard
Priority: P3 → P4
Whiteboard: [nsbeta3+] → [nsbeta3+][p:4]
accepting bug
Status: NEW → ASSIGNED
PDT downloading to nsbeta3-.  No crash thus not critical to PR3 and RTM.
Whiteboard: [nsbeta3+][p:4] → [nsbeta3-][p:4][minus]
fixed
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
marking verified.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.