Closed Bug 1055838 Opened 10 years ago Closed 10 years ago

MediaEngineDefaultVideoSource::MediaEngineDefaultVideoSource fails to initialise mCb, mCr

Categories

(Core :: WebRTC, defect)

x86_64
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla34

People

(Reporter: jseward, Assigned: jseward)

Details

Attachments

(1 file)

test_path = content/media/test/test_mediarecorder_record_gum_video_timeslice.html

the consequence of which is that there's a whole bunch of Valgrind complaining
later on, since the values get pushed into the vp8 codeccery stack.
A couple of representative errors are shown in the next comment.
First appearance:

Thread 39 MediaManager:
Conditional jump or move depends on uninitialised value(s)
   at 0x6C93A9D: mozilla::MediaEngineDefaultVideoSource::Notify(nsITimer*) (content/media/webrtc/MediaEngineDefault.cpp:221)
   by 0x58417E9: nsTimerImpl::Fire() (xpcom/threads/nsTimerImpl.cpp:621)
   by 0x5842706: nsTimerEvent::Run() (xpcom/threads/nsTimerImpl.cpp:711)
   by 0x583D957: nsThread::ProcessNextEvent(bool, bool*) (xpcom/threads/nsThread.cpp:770)
   by 0x585D1AF: NS_ProcessNextEvent(nsIThread*, bool) (xpcom/glue/nsThreadUtils.cpp:265)
   by 0x5ABC2BB: mozilla::ipc::MessagePumpForNonMainThreads::Run(base::MessagePump::Delegate*) (ipc/glue/MessagePump.cpp:326)
   by 0x5A98209: MessageLoop::RunInternal() (ipc/chromium/src/base/message_loop.cc:229)
   by 0x5A98214: MessageLoop::RunHandler() (ipc/chromium/src/base/message_loop.cc:222)
   by 0x5A984D9: MessageLoop::Run() (ipc/chromium/src/base/message_loop.cc:196)
   by 0x5840BF3: nsThread::ThreadFunc(void*) (xpcom/threads/nsThread.cpp:347)
   by 0x4C666F7: _pt_root (nsprpub/pr/src/pthreads/ptthread.c:212)
   by 0x349F407D13: start_thread (/usr/src/debug/glibc-2.15-a316c1f/nptl/pthread_create.c:309)
   by 0x349F0F168C: clone (/usr/src/debug////////glibc-2.15-a316c1f/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:115)

 Uninitialised value was created by a heap allocation
   at 0x4809064: malloc (/home/sewardj/VgTRUNK/mozhx/coregrind/m_replacemalloc/vg_replace_malloc.c:298)
   by 0x481D86B: moz_xmalloc (memory/mozalloc/mozalloc.cpp:52)
   by 0x6C960B6: operator new (ff-O-linux64/content/media/webrtc/../../../dist/include/mozilla/mozalloc.h:201)
   by 0x6C960B6: mozilla::MediaEngineDefault::EnumerateVideoDevices(mozilla::MediaSourceType, nsTArray<nsRefPtr<mozilla::Medi
   by 0x684BE47: nsTArray<nsCOMPtr<nsIMediaDevice> >* mozilla::GetSources<mozilla::MediaEngineVideoSource, mozilla::VideoTrac
   by 0x68506D5: mozilla::GetUserMediaRunnable::SelectDevice(mozilla::MediaEngine*) (dom/media/MediaManager.cpp:1127)
   by 0x6850FE4: mozilla::GetUserMediaRunnable::Run() (dom/media/MediaManager.cpp:1037)
   by 0x583D957: nsThread::ProcessNextEvent(bool, bool*) (xpcom/threads/nsThread.cpp:770)
   by 0x585D1AF: NS_ProcessNextEvent(nsIThread*, bool) (xpcom/glue/nsThreadUtils.cpp:265)
   by 0x5ABC2BB: mozilla::ipc::MessagePumpForNonMainThreads::Run(base::MessagePump::Delegate*) (ipc/glue/MessagePump.cpp:326)
   by 0x5A98209: MessageLoop::RunInternal() (ipc/chromium/src/base/message_loop.cc:229)
   by 0x5A98214: MessageLoop::RunHandler() (ipc/chromium/src/base/message_loop.cc:222)
   by 0x5A984D9: MessageLoop::Run() (ipc/chromium/src/base/message_loop.cc:196)
   by 0x5840BF3: nsThread::ThreadFunc(void*) (xpcom/threads/nsThread.cpp:347)
   by 0x4C666F7: _pt_root (nsprpub/pr/src/pthreads/ptthread.c:212)
   by 0x349F407D13: start_thread (/usr/src/debug/glibc-2.15-a316c1f/nptl/pthread_create.c:309)
   by 0x349F0F168C: clone (/usr/src/debug////////glibc-2.15-a316c1f/misc/../sysdeps/unix/sysv/linux/x86_64/clone.S:115)

Later on, zillions of this kind of thing, w/ same uninit-value origin

Conditional jump or move depends on uninitialised value(s)
   at 0x75460CB: pick_intra_mbuv_mode (media/libvpx/vp8/encoder/pickinter.c:380)
   by 0x754E6DE: vp8_pick_intra_mode (media/libvpx/vp8/encoder/pickinter.c:1261)
   by 0x753C59D: vp8cx_encode_intra_macroblock (media/libvpx/vp8/encoder/encodeframe.c:1172)
   by 0x753D7C9: encode_mb_row (media/libvpx/vp8/encoder/encodeframe.c:502)
   by 0x753EE61: vp8_encode_frame (media/libvpx/vp8/encoder/encodeframe.c:922)
   by 0x754FD14: encode_frame_to_data_rate (media/libvpx/vp8/encoder/onyx_if.c:4018)
   by 0x7551C13: vp8_get_compressed_data (media/libvpx/vp8/encoder/onyx_if.c:5177)
   by 0x7554143: vp8e_encode (media/libvpx/vp8/vp8_cx_iface.c:872)
   by 0x75B76A0: vpx_codec_encode (media/libvpx/vpx/src/vpx_encoder.c:226)
   by 0x6C31568: mozilla::VP8TrackEncoder::GetEncodedTrack(mozilla::EncodedFrameContainer&) (content/media/encoder/VP8TrackEncoder.cpp:512)
   by 0x6C311B6: mozilla::MediaEncoder::WriteEncodedDataToMuxer(mozilla::TrackEncoder*) (content/media/encoder/MediaEncoder.cpp:272)
   by 0x6C312C8: mozilla::MediaEncoder::GetEncodedData(nsTArray<nsTArray<unsigned char> >*, nsAString_internal&) (content/media/encoder/MediaEncoder.cpp:227)
   by 0x6C25ABE: mozilla::dom::MediaRecorder::Session::Extract(bool) (content/media/MediaRecorder.cpp:359)
   by 0x6C25D23: mozilla::dom::MediaRecorder::Session::ExtractRunnable::Run() (content/media/MediaRecorder.cpp:172)
   by 0x583D957: nsThread::ProcessNextEvent(bool, bool*) (xpcom/threads/nsThread.cpp:770)
   by 0x585D1AF: NS_ProcessNextEvent(nsIThread*, bool) (xpcom/glue/nsThreadUtils.cpp:265)
 Uninitialised value was created by a heap allocation
   [.. same as before ..]
The obvious fix.
Attachment #8475545 - Flags: review?(tterribe)
Attachment #8475545 - Flags: review?(tterribe) → review+
https://hg.mozilla.org/mozilla-central/rev/0ed4b3b8d79b
Assignee: nobody → jseward
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla34
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: