Created attachment 468796 [details] testcase See testcase, which crashes current trunk build and Firefox3.6.8. http://crash-stats.mozilla.com/report/index/bp-c88327df-4ec8-4970-8c25-fe09d2100824 0 xul.dll nsSVGGlyphFrame::GetExtentOfChar layout/svg/base/src/nsSVGGlyphFrame.cpp:1077 1 xul.dll nsSVGTextContainerFrame::GetExtentOfChar layout/svg/base/src/nsSVGTextContainerFrame.cpp:195 2 xul.dll nsSVGTextElement::GetExtentOfChar content/svg/content/src/nsSVGTextElement.cpp:324 3 xul.dll NS_InvokeByIndex_P xpcom/reflect/xptcall/src/md/win32/xptcinvoke.cpp:102 4 xul.dll js::InvokeCommon<int > js/src/jsinterp.cpp:566 5 xul.dll js::Invoke js/src/jsinterp.cpp:699 6 xul.dll js::Interpret js/src/jsinterp.cpp:4709 7 xul.dll js::Execute js/src/jsinterp.cpp:883 8 xul.dll JS_EvaluateUCScriptForPrincipals js/src/jsapi.cpp:4769 9 xul.dll nsJSContext::EvaluateString dom/base/nsJSEnvironment.cpp:1811 10 xul.dll nsScriptLoader::EvaluateScript content/base/src/nsScriptLoader.cpp:767 11 xul.dll nsScriptLoader::ProcessRequest content/base/src/nsScriptLoader.cpp:677 12 xul.dll nsScriptLoader::ProcessScriptElement content/base/src/nsScriptLoader.cpp:617 13 xul.dll nsScriptElement::MaybeProcessScript content/base/src/nsScriptElement.cpp:195 14 xul.dll nsSVGScriptElement::DoneAddingChildren content/svg/content/src/nsSVGScriptElement.cpp:280 15 xul.dll nsXMLContentSink::CloseElement etc..
Crashes on Mac as well, changing to all.
Jwatt, any updates here? Marking sg:critical? until we learn more about the reason for this crash.
I think this is an sg:dos null deref. The crash-stacks on windows point at an uninteresting line 1077, but I think the optimizer is playing games with the loops. In mac debug and opt builds build I crash just after calling GetLength() on a null mTextRun. I don't understand why I don't crash calling mTextRun->IsClusterStart(limit) first though. In the debug build it ran quite a long time before crashing. Is it possible we're reusing a dead object that just happens to have nulls in an opt build?
Doesn't crash 1.9.0 or 1.9.1. The code that's crashing was added in bug 478792 http://hg.mozilla.org/mozilla-central/rev/f6cdd2d6a9ea
Created attachment 471012 [details] [diff] [review] patch the CharacterIterator tries to create the mTextRun so that needs to come first. In this case even that does not set a mTextRun since we go into an error state with mInError = true. Chicken and egg at first sight since you need to advance to detect the error and you need a text run to figure out where to advance to but you can just advance to the beginning of the string and then figure out whether you need to advance any more later.
Is that it for me in the brave new world of security fixes being checked in by the security group? The patch should apply to both trunk and 1.9.2 though you may need to fuzz things a little for the branch.
Comment on attachment 471012 [details] [diff] [review] patch Approved for 22.214.171.124, a=dveditz Please land this fix on trunk and the 1.9.2 branch.
(We're not really using the private repositories yet.)
pushed http://hg.mozilla.org/mozilla-central/rev/29b9772d0c3a pushed http://hg.mozilla.org/releases/mozilla-1.9.2/rev/8d2f5d3141c7
Verified fixed for 1.9.2 with Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:126.96.36.199pre) Gecko/20100921 Namoroka/3.6.11pre. Verified crash with testcase in 188.8.131.52.
I see that this shipped, but without any credit for cross_fuzz? Bummer :-(
I think Martijn, the original reporter, wasn't using cross_fuzz.
Oh, he was. Sorry.
Is cross_fuzz public? I thought it wasn't and I don't know with whom you've shared it. Didn't want to start a deluge of "why won't you share it with _me_?" requests headed your way. Should we add a note like the ones in MFSA 2010-49 and MFSA 2010-59 every time we fix a crossfuzz-found bug? Forever? Until the fuzzer is public?
It's not public, it's shared with all the major browser vendors (as all are affected). I certainly don't mind a deluge of requests (if there's one thing I'm good at, it's turning people down). It's no big deal, really; it'd be cool to get a customary acknowledgment on fixed bugs, as it's pretty much the currency in the open source infosec world - but it's your call, depending on how much you believe cross_fuzz actually contributed to spotting the flaw, etc.