Last Comment Bug 386254 - Crash [@ nsTextControlFrame::SetValue] on branch with testcase2 from bug 373586
: Crash [@ nsTextControlFrame::SetValue] on branch with testcase2 from bug 373586
[sg:moderate?] requires chrome? uses ...
: crash, testcase, topcrash, verified1.8.0.13, verified1.8.1.5
Product: Core
Classification: Components
Component: Layout (show other bugs)
: 1.8 Branch
: x86 Windows XP
-- critical (vote)
: ---
Assigned To: Olli Pettay [:smaug] (pto-ish for couple of days)
: Jet Villegas (:jet)
: 383120 (view as bug list)
Depends on: 373586 386561
  Show dependency treegraph
Reported: 2007-06-28 15:04 PDT by Martijn Wargers [:mwargers]
Modified: 2011-06-13 10:01 PDT (History)
6 users (show)
dveditz: wanted1.8.1.x+
dveditz: wanted1.8.0.x+
dveditz: in‑testsuite?
See Also:
Crash Signature:
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---

possible patch (7.12 KB, patch)
2007-07-02 01:44 PDT, Olli Pettay [:smaug] (pto-ish for couple of days)
roc: review+
roc: superreview+
dveditz: approval1.8.1.5+
dveditz: approval1.8.0.13+
Details | Diff | Splinter Review

Description User image Martijn Wargers [:mwargers] 2007-06-28 15:04:40 PDT
See url, you need to download the testcase to your computer to get the crash, because of enhanced privileges.

This is a follow-up from bug 373586.

From comment 23 in that bug:
This crashes current branch builds when clicking on the button. You need to run
the testcase from chrome.
I get a [@ nsTextControlFrame::SetValue] (talkback ID: TB32917810X).
It doesn't crash on trunk, I think it's because of this patch.
I think this is currently nr. 29 of the hit list of crashes on branch:

Smaug, maybe this can be fixed by just a null-check?
Comment 1 User image Olli Pettay [:smaug] (pto-ish for couple of days) 2007-06-29 09:28:48 PDT
I don't think so. I added a weakframe test and it showed that the frame got 
deleted. Probably something similar what bug 373586 did for ::SetValue is needed.
Comment 2 User image Olli Pettay [:smaug] (pto-ish for couple of days) 2007-07-02 01:44:25 PDT
Created attachment 270554 [details] [diff] [review]
possible patch

Making the ::SetValue to have similar checks as what are currently on 
trunk. However with the patch using the testcase, the painting of the
page doesn't work correctly after pressing the button. (Painting
works ok when loading a new page.) The same painting problem happens
on trunk too, so I could just file a new (Non-SSensitive) bug for that.
The patch is needed anyway, though.
Comment 3 User image Daniel Veditz [:dveditz] 2007-07-02 11:10:00 PDT
waiting to give branch approval until this shakes out a bit on trunk and we figure out fixes for the painting regression.
Comment 4 User image Daniel Veditz [:dveditz] 2007-07-03 13:33:15 PDT
Is there a way to trigger this situation without requiring chrome or UniversalXPConnect privileges? It's clearly using a deleted editor object, but if you need privileged code to get there then it's not an exploit.

Is the top-crash in this routine likely the same thing? If so then maybe there is a non-chrome way to exploit this. A lot of the talkbacks for this location die on the same "mEditor->SetFlags(savedFlags);" line I die on (and the rest say line "848" which isn't anywhere near this routine and which I'd chalk up to a glitch if it weren't so common and consistent a location). I guess the talkbacks pointing to the same object dereference makes me worry.

Whether we want to risk the regressions for the branch hinges on the answer to the above.

How bad is the painting regression? (shouldn't the bug have the regression keyword?).
Comment 5 User image Daniel Veditz [:dveditz] 2007-07-06 14:53:12 PDT
Comment on attachment 270554 [details] [diff] [review]
possible patch

approved for and, a=dveditz for release-drivers
Comment 6 User image Martijn Wargers [:mwargers] 2007-07-10 14:59:23 PDT
Verified fixed, using:
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20070709

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv: Gecko/20070710

The testcase doesn't crash anymore after clicking on the button.
Comment 7 User image Alexander Sack 2008-04-21 04:31:38 PDT
*** Bug 383120 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.