Opened 14 years ago

Closed 9 years ago

#7180 closed bug (fixed)

Media Server crashing when shutting down/used with cortex/randomly with media files (float_to_float())

Reported by: stargatefan Owned by: pulkomandy
Priority: normal Milestone: R1
Component: Add-Ons/Media/Mixer Version: R1/Development
Keywords: Cc: black.belt.jimmy@…, degea@…
Blocked By: Blocking: #10344, #10492, #11339
Platform: All

Description (last modified by diver)

Was trying to use cortex to see if inputs and output worked. I was met with failure.

Thread 2492 caused an exception: Segment violation
[...]
[Switching to team /boot/system/servers/media_addon_server (2474) thread Audio Mixer control (2492)]
0x00956d89 in Resampler::float_to_float ()
   from /boot/system/add-ons/media/mixer.media_addon
(gdb) bt
#0  0x00956d89 in Resampler::float_to_float ()
   from /boot/system/add-ons/media/mixer.media_addon
#1  0x0095289f in MixerInput::BufferReceived ()
   from /boot/system/add-ons/media/mixer.media_addon
#2  0x00950222 in MixerCore::BufferReceived ()
   from /boot/system/add-ons/media/mixer.media_addon
#3  0x0094d58f in AudioMixer::HandleInputBuffer ()
   from /boot/system/add-ons/media/mixer.media_addon
#4  0x0094d5fa in AudioMixer::HandleEvent ()
   from /boot/system/add-ons/media/mixer.media_addon
#5  0x004c443b in BMediaEventLooper::DispatchEvent ()
   from /boot/system/lib/libmedia.so
#6  0x004c4ab7 in BMediaEventLooper::ControlLoop ()
   from /boot/system/lib/libmedia.so
#7  0x004c43a9 in BMediaEventLooper::_ControlThreadStart ()
   from /boot/system/lib/libmedia.so
#8  0x00657060 in thread_entry () from /boot/system/lib/libroot.so
#9  0x701c5fec in ?? ()
(gdb) 

Change History (15)

comment:1 by stargatefan, 14 years ago

Summary: Media Server crashing when used with CortexMedia Server crashing when shttuing down/used with cortex/randomly with media files

Still seeing random crashes with media server at shut down. It also has trouble with files that may or may not have missing frames. Problem seemed to drop up in the 402xx series IIRC. I could try to narrow it down but it could just be a flue to. I have seen it on the nightlies to0.

Easy to reproduce Install nightly iso with hda, shut machine down. gcc4 hybrid hrev40356

Thread 200 called debugger(): oops
[...]
[Switching to team /boot/system/servers/media_addon_server (145) thread Audio Mixer control (200)]
0xffff0114 in ?? ()
(gdb) bt
#0  0xffff0114 in ?? ()
#1  0x006541db in debugger () from /boot/system/lib/libroot.so
#2  0x004bb80e in BBuffer::SetHeader () from /boot/system/lib/libmedia.so
#3  0x004bc840 in BBufferConsumer::HandleMessage ()
   from /boot/system/lib/libmedia.so
#4  0x004cac58 in BMediaNode::WaitForMessage ()
   from /boot/system/lib/libmedia.so
#5  0x004c597e in BMediaEventLooper::ControlLoop ()
   from /boot/system/lib/libmedia.so
#6  0x004c53a9 in BMediaEventLooper::_ControlThreadStart ()
   from /boot/system/lib/libmedia.so
#7  0x00658070 in thread_entry () from /boot/system/lib/libroot.so
#8  0x701c5fec in ?? ()
(gdb)
Last edited 11 years ago by diver (previous) (diff)

comment:2 by bbjimmy, 13 years ago

Cc: black.belt.jimmy@… added

comment:3 by diver, 11 years ago

Component: Servers/media_serverServers/media_addon_server
Description: modified (diff)

comment:4 by diver, 11 years ago

Blocking: 10344 added

comment:5 by diver, 11 years ago

Component: Servers/media_addon_serverAdd-Ons/Media/Mixer
Description: modified (diff)
Owner: changed from axeld to pulkomandy
Status: newassigned
Version: R1/alpha2R1/Development

comment:6 by pulkomandy, 11 years ago

Blocking: 10344 removed

(In #10344) the crash is in the resampler code. Switching from "linear interpolation" to "drop/repeat sample" is a safer way to avoid this problem (even for apps not generating 48kHz output). the drop/repeat code is ok, only the interpolated one is buggy (seem to do an out of bounds access from time to time).

Also, reopening this as a separate issue, the backtrace in #7180 isn't the same.

comment:7 by pulkomandy, 11 years ago

Blocking: 10344 added

(In #10344) Oops, you're right, I was looking at the stacktrace in the first comment there.

comment:8 by pulkomandy, 11 years ago

Blocking: 10344 removed

And, @stargatefan: your problem is unrelated, if it still happens, please open a separate ticket.

comment:9 by pulkomandy, 11 years ago

Blocked By: 10344 added

comment:10 by diver, 11 years ago

Blocking: 10492 added

comment:11 by diver, 11 years ago

Blocked By: 10344 removed
Blocking: 10344 added

comment:12 by diver, 10 years ago

Blocking: 11339 added

comment:13 by ttcoder, 10 years ago

Cc: degea@… added
Summary: Media Server crashing when shttuing down/used with cortex/randomly with media filesMedia Server crashing when shutting down/used with cortex/randomly with media files (float_to_float())

Had that one occur reliably a few seconds after boot-up (not shutting down) after doing a sorta 'manual' upgrade to 47896 last week.. Once in int_to_float and the rest of the times in float_to_float(). Scared the heck out of me :-).. Now did a proper (pkgman) update to 47991 and audio works correctly. I always use drop/repeate samples BTW, never interpolation. Anyway I blame it on the cranky manual update, hope to never see this again :-)

comment:14 by Barrett, 10 years ago

After my patch at #6188 this should be checked as the two bugs seems two effects of the same cause.

comment:15 by Barrett, 9 years ago

Resolution: fixed
Status: assignedclosed

Fixed in hrev49503.

Note: See TracTickets for help on using tickets.