[mythtv-commits] Ticket #10809: [PATCH] libmyth: Prevent an access violation by the ALSA library

MythTV noreply at mythtv.org
Wed Jun 6 17:05:56 UTC 2012

#10809: [PATCH] libmyth: Prevent an access violation by the ALSA library
     Reporter:  Lawrence Rust        |      Owner:  jyavenard
  <lvr@…>                            |     Status:  new
         Type:  Patch - Bug Fix      |  Milestone:  unknown
     Priority:  minor                |    Version:  Master Head
    Component:  MythTV - Audio       |   Keywords:  ALSA
  Output                             |  snd_device_name_hint
     Severity:  medium               |
Ticket locked:  0                    |
 In audiooutputalsa.cpp, AudioOutputALSA::GetDevices calls the ALSA API
 snd_device_name_hint with a card index of -1 to obtain a list of hints for
 all cards.  Unfortunately, with libasound.so.2.0 this API can cause an
 access violation when the card index is -1. See

 Running with valgrind shows that snd_device_name_hint makes reference to
 previously freed memory when called with a card index of -1.

 This patch enumerates the cards using other ALSA APIs, thus avoiding the

 The access violation is often seen when starting from an empty dbase and
 attempting to enter the audio setup screen.  The bug also applies to
 fixes/0.25 and 0.24.

Ticket URL: <http://code.mythtv.org/trac/ticket/10809>
MythTV <http://code.mythtv.org/trac>
MythTV Media Center

More information about the mythtv-commits mailing list