Closed Bug 1177565 Opened 9 years ago Closed 9 years ago

~15,000 instances of 'NS_ENSURE_SUCCESS(EnsureScriptEnvironment(), nullptr) failed with result 0x80040111' emitted from docshell/base/nsDocShell.cpp during linux64 debug testing

Categories

(Core :: DOM: Navigation, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla42
Tracking Status
firefox42 --- fixed

People

(Reporter: erahm, Assigned: erahm)

References

(Blocks 1 open bug)

Details

Attachments

(1 file)

> 14754 [NNNNN] WARNING: NS_ENSURE_SUCCESS(EnsureScriptEnvironment(), nullptr) failed with result 0x80040111: file docshell/base/nsDocShell.cpp, line 4607 0x80040111 is NS_ERROR_NOT_AVAILABLE. This warning [1] is rather widespread across tests, it is most frequent during mochitest-browser-chrome-2, a few more verbose tests: > 97 warnings from test browser/components/sessionstore/test/browser_354894_perwindowpb.js > 76 warnings from test browser/components/sessionstore/test/browser_522545.js > 48 warnings from test browser/components/downloads/test/browser/browser_iframe_gone_mid_download.js It looks like this can happen if |mIsBeingDestroyed| is true [2] or if |do_GetInterface(mTreeOwner)| fails [3]. Given the frequency of this warning it seems like we should just remove it (or possibly move it to |EnsureScriptEnvironment| where we can get a better idea of what is actually failing). [1] https://hg.mozilla.org/mozilla-central/annotate/02f640a72dcd/docshell/base/nsDocShell.cpp#l4607 [2] https://hg.mozilla.org/mozilla-central/annotate/0b2f5e8b7be5/docshell/base/nsDocShell.cpp#l12780 [3] https://hg.mozilla.org/mozilla-central/annotate/0b2f5e8b7be5/docshell/base/nsDocShell.cpp#l12795
Note: This is the most verbose warning during linux64 debug testing.
Attachment #8626364 - Flags: review?(bugs)
Assignee: nobody → erahm
Status: NEW → ASSIGNED
Comment on attachment 8626364 [details] [diff] [review] Stop warning if EnsureScriptEnvironment returns NS_ERROR_NOT_AVAILABLE I don't think it is useful to warn ever. So just return NS_SUCCEEDED(EnsureScriptEnvironment()) ? mScriptGlobal : nullptr; Or even EnsureScriptEnvironment(); return mScriptGlobal; But I think I'd prefer the first one.
Attachment #8626364 - Flags: review?(bugs) → review+
(In reply to Olli Pettay [:smaug] from comment #2) > Comment on attachment 8626364 [details] [diff] [review] > Stop warning if EnsureScriptEnvironment returns NS_ERROR_NOT_AVAILABLE > > I don't think it is useful to warn ever. > So just > > return NS_SUCCEEDED(EnsureScriptEnvironment()) ? mScriptGlobal : nullptr; > > Or even > EnsureScriptEnvironment(); > return mScriptGlobal; > > But I think I'd prefer the first one. Thanks for the quick review! I'll update to use the tristate.
Blocks: logspam
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla42
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: