Browse Source

alsa: avoid uninitialized read

The check if ( subdevice != -1 ) was being done on a potentially
uninitialized variable.
tags/4.1.2
Tristan Matthews 11 years ago
parent
commit
7efec74033
1 changed files with 1 additions and 0 deletions
  1. +1
    -0
      RtAudio.cpp

+ 1
- 0
RtAudio.cpp View File

@@ -6815,6 +6815,7 @@ RtAudio::DeviceInfo RtApiAlsa :: getDeviceInfo( unsigned int device )
// Count cards and devices
card = -1;
subdevice = -1;
snd_card_next( &card );
while ( card >= 0 ) {
sprintf( name, "hw:%d", card );


Loading…
Cancel
Save