cwAudioDeviceAlsa.cpp : Removed trailing white space from the device description string.
This commit is contained in:
parent
05d0c316f4
commit
bc98a92f0a
@ -4,6 +4,7 @@
|
|||||||
#include "cwTest.h"
|
#include "cwTest.h"
|
||||||
#include "cwMem.h"
|
#include "cwMem.h"
|
||||||
#include "cwTime.h"
|
#include "cwTime.h"
|
||||||
|
#include "cwText.h"
|
||||||
#include "cwTextBuf.h"
|
#include "cwTextBuf.h"
|
||||||
#include "cwThread.h"
|
#include "cwThread.h"
|
||||||
#include "cwAudioDevice.h"
|
#include "cwAudioDevice.h"
|
||||||
@ -1303,6 +1304,9 @@ cw::rc_t cw::audio::device::alsa::create( handle_t& hRef, struct driver_str*& dr
|
|||||||
dr.nameStr = mem::printf(dr.nameStr,"hw:%i,%i,%i",cardNum,devNum,i);
|
dr.nameStr = mem::printf(dr.nameStr,"hw:%i,%i,%i",cardNum,devNum,i);
|
||||||
dr.descStr = mem::printf(dr.descStr,"%s %s",cardNamePtr,snd_pcm_info_get_name(info));
|
dr.descStr = mem::printf(dr.descStr,"%s %s",cardNamePtr,snd_pcm_info_get_name(info));
|
||||||
|
|
||||||
|
// it's possible that trailing whitespace is left in the desc
|
||||||
|
removeTrailingWhitespace( dr.descStr );
|
||||||
|
|
||||||
// attempt to open the sub-device
|
// attempt to open the sub-device
|
||||||
if((err = _devOpen(&pcmH,dr.nameStr,inputFl)) < 0 )
|
if((err = _devOpen(&pcmH,dr.nameStr,inputFl)) < 0 )
|
||||||
_alsaSetupError(err,inputFl,&dr,"Unable to open the PCM handle");
|
_alsaSetupError(err,inputFl,&dr,"Unable to open the PCM handle");
|
||||||
|
Loading…
Reference in New Issue
Block a user