Closed Bug 915507 Opened 11 years ago Closed 11 years ago

Intermittent TestAudioChannelService | test failed with return code 256

Categories

(Core :: DOM: Core & HTML, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla27
Tracking Status
firefox25 --- wontfix
firefox26 --- fixed
firefox27 --- fixed
firefox-esr24 --- wontfix
b2g-v1.2 --- fixed

People

(Reporter: philor, Assigned: mchen)

Details

(Keywords: intermittent-failure)

Attachments

(1 file, 1 obsolete file)

https://tbpl.mozilla.org/php/getParsedLog.php?id=27741360&tree=Mozilla-Inbound Linux x86-64 mozilla-inbound debug asan build on 2013-09-11 16:43:26 PDT for push 3ca22e239a1d slave: bld-linux64-ec2-363 ... WARNING: XPCOM objects created/destroyed from static ctor/dtor: file /builds/slave/m-in-l64-asan-d-00000000000000/build/xpcom/base/nsTraceRefcntImpl.cpp, line 141 ASAN:SIGSEGV ================================================================= ==14811==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f6b33d4079e sp 0x7fffed331ec0 bp 0x7fffed331ff0 T0) AddressSanitizer can not provide additional info. #0 0x7f6b33d4079d (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x30af79d) #1 0x7f6b34e4506e (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x41b406e) #2 0x7f6b37f1ac53 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x7289c53) #3 0x7f6b37f1ae29 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x7289e29) #4 0x7f6b37c65635 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fd4635) #5 0x7f6b37c61f4b (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fd0f4b) #6 0x7f6b37c73f27 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fe2f27) #7 0x7f6b37c6da43 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fdca43) #8 0x7f6b37c61f4b (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fd0f4b) #9 0x7f6b37c75f87 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fe4f87) #10 0x7f6b37c76541 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x6fe5541) #11 0x7f6b37ecdad3 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x723cad3) #12 0x7f6b37ecdefd (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x723cefd) #13 0x7f6b37d6cc5e (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x70dbc5e) #14 0x7f6b37f16af5 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x7285af5) #15 0x7f6b34ee15c8 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x42505c8) #16 0x7f6b34ee14ad (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x42504ad) #17 0x7f6b34ee105c (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x425005c) #18 0x7f6b34e67108 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x41d6108) #19 0x7f6b36704e6c (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x5a73e6c) #20 0x7f6b36704de5 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x5a73de5) #21 0x7f6b367048c7 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x5a738c7) #22 0x7f6b36704755 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x5a73755) #23 0x7f6b366fcfb0 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x5a6bfb0) #24 0x7f6b3666f90f (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dist/bin/libxul.so+0x59de90f) #25 0x45f8cb (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dom/audiochannel/tests/TestAudioChannelService+0x45f8cb) #26 0x45cd67 (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dom/audiochannel/tests/TestAudioChannelService+0x45cd67) #27 0x7f6b2f4aacdc (/lib64/libc.so.6+0x1ecdc) #28 0x4593bc (/builds/slave/m-in-l64-asan-d-00000000000000/build/obj-firefox/dom/audiochannel/tests/TestAudioChannelService+0x4593bc) ==14811==ABORTING cppunittests TEST-UNEXPECTED-FAIL | TestAudioChannelService | test failed with return code 256
That's a regular crash and here is the symbolized trace: ================================================================= ==14811==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x7f6b33d4079e sp 0x7fffed331ec0 bp 0x7fffed331ff0 T0) AddressSanitizer can not provide additional info. #0 0x7f6b33d4079d in nsContentUtils::GetSubjectPrincipal() content/base/src/nsContentUtils.cpp:2394 #1 0x7f6b34e4506e in XPCJSRuntime::OperationCallback(JSContext*) js/xpconnect/src/XPCJSRuntime.cpp:1254 #2 0x7f6b37f1ac53 in js_InvokeOperationCallback(JSContext*) js/src/jscntxt.cpp:1043 #3 0x7f6b37f1ae29 in js_HandleExecutionInterrupt(JSContext*) js/src/jscntxt.cpp:1050 #4 0x7f6b37c65635 in Interpret(JSContext*, js::RunState&) js/src/vm/Interpreter.cpp:1705 #5 0x7f6b37c61f4b in js::RunScript(JSContext*, js::RunState&) js/src/vm/Interpreter.cpp:435 #6 0x7f6b37c73f27 in js::Invoke(JSContext*, JS::CallArgs, js::MaybeConstruct) js/src/vm/Interpreter.cpp:497 #7 0x7f6b37c6da43 in Interpret(JSContext*, js::RunState&) js/src/vm/Interpreter.cpp:2454 #8 0x7f6b37c61f4b in js::RunScript(JSContext*, js::RunState&) js/src/vm/Interpreter.cpp:435 #9 0x7f6b37c75f87 in js::ExecuteKernel(JSContext*, JS::Handle<JSScript*>, JSObject&, JS::Value const&, js::ExecuteType, js::AbstractFramePtr, JS::Value*) js/src/vm/Interpreter.cpp:619 #10 0x7f6b37c76541 in js::Execute(JSContext*, JS::Handle<JSScript*>, JSObject&, JS::Value*) js/src/vm/Interpreter.cpp:655 #11 0x7f6b37ecdad3 in JS::Evaluate(JSContext*, JS::Handle<JSObject*>, JS::CompileOptions, unsigned short const*, unsigned long, JS::Value*) js/src/jsapi.cpp:4898 #12 0x7f6b37ecdefd in JS::Evaluate(JSContext*, JS::Handle<JSObject*>, JS::CompileOptions, char const*, unsigned long, JS::Value*) js/src/jsapi.cpp:4928 #13 0x7f6b37d6cc5e in JSRuntime::initSelfHosting(JSContext*) js/src/vm/SelfHosting.cpp:761 #14 0x7f6b37f16af5 in js::NewContext(JSRuntime*, unsigned long) js/src/jscntxt.cpp:201 #15 0x7f6b34ee15c8 in ~nsXPConnect js/xpconnect/src/nsXPConnect.cpp:105 #16 0x7f6b34ee14ad in ~nsXPConnect js/xpconnect/src/nsXPConnect.cpp:97 #17 0x7f6b34ee105c in nsXPConnect::Release() js/xpconnect/src/nsXPConnect.cpp:55 #18 0x7f6b34e67108 in xpcModuleDtor() js/xpconnect/src/XPCModule.cpp:23 #19 0x7f6b36704e6c in ~KnownModule xpcom/components/nsComponentManager.h:224 #20 0x7f6b36704de5 in ~nsAutoPtr obj-firefox/xpcom/components/../../dist/include/nsAutoPtr.h:77 #21 0x7f6b367048c7 in nsTArray_Impl<nsAutoPtr<nsComponentManagerImpl::KnownModule>, nsTArrayInfallibleAllocator>::DestructRange(unsigned int, unsigned int) obj-firefox/xpcom/components/../../dist/include/nsTArray.h:1569 #22 0x7f6b36704755 in nsTArray_Impl<nsAutoPtr<nsComponentManagerImpl::KnownModule>, nsTArrayInfallibleAllocator>::RemoveElementsAt(unsigned int, unsigned int) obj-firefox/xpcom/components/../../dist/include/nsTArray.h:1286 addr2line: '/lib64/libc.so.6': No such file #23 0x7f6b366fcfb0 in nsComponentManagerImpl::Shutdown() xpcom/components/nsComponentManager.cpp:808 #24 0x7f6b3666f90f in mozilla::ShutdownXPCOM(nsIServiceManager*) xpcom/build/nsXPComInit.cpp:771 #25 0x45f8cb in ?? ??:0 #26 0x45cd67 in ?? ??:0 #27 0x7f6b2f4aacdc in #28 0x4593bc in ?? ??:0 ==14811==ABORTING cppunittests TEST-UNEXPECTED-FAIL | TestAudioChannelService | test failed with return code 256 We really need to get symbolizing to work on TBPL, such that the traces are properly converted before going into the log.
I found one thing is that Agent class in testAudioChannelService didn't not inherite weakreference, so it tried to initilize AudioChannelAgent with init(...) not InitWithWeakCallback(...). this will cause a circular reference between Agent and AudioChannelAgent class. Then finally Agent instance will be leaked.
Attached patch Patch v1 - solve memory leak (obsolete) — Splinter Review
Hi Andrea, This patch let Agent inherit nsSupportsWeakReference so it can use InitWithWeakCallback() from AudioChannelAgent. This can break the circular reference between Agent & AudioChannelAgent then solve the memory leak issue. Thanks.
Assignee: nobody → mchen
Attachment #812429 - Flags: review?(amarchesini)
Comment on attachment 812429 [details] [diff] [review] Patch v1 - solve memory leak Review of attachment 812429 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/audiochannel/tests/TestAudioChannelService.cpp @@ +41,5 @@ > } > > + virtual ~Agent() > + { > + if (mRegistered) if (mRegistered) {
Attachment #812429 - Flags: review?(amarchesini) → review+
1. Carry in reviewer's name. 2. Fix the nits.
Attachment #812429 - Attachment is obsolete: true
Attachment #817054 - Flags: review+
Keywords: checkin-needed
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: