summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/4a-hal-utilities/4a-hal-utilities-data.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/4a-hal-utilities/4a-hal-utilities-data.c b/lib/4a-hal-utilities/4a-hal-utilities-data.c
index 1e20c59..8f30596 100644
--- a/lib/4a-hal-utilities/4a-hal-utilities-data.c
+++ b/lib/4a-hal-utilities/4a-hal-utilities-data.c
@@ -132,14 +132,15 @@ struct InternalHalMixerData *HalUtlSearchMixerDataByProperties(struct InternalHa
{
struct InternalHalMixerData *currentMixerData;
- if(! mixerDataList || ! *mixerDataList || ! verb)
+ if(! mixerDataList || ! *mixerDataList || ! verb || ! verbToCall)
return NULL;
currentMixerData = *mixerDataList;
while(currentMixerData) {
- if((! strcmp(verb, currentMixerData->verb)) &&
- (! strcmp(verbToCall, currentMixerData->verbToCall)) &&
- (! strcmp(streamCardId, currentMixerData->streamCardId)))
+ if(! strcmp(verb, currentMixerData->verb) &&
+ ! strcmp(verbToCall, currentMixerData->verbToCall) &&
+ ((! streamCardId && ! currentMixerData->streamCardId) ||
+ (streamCardId && currentMixerData->streamCardId && ! strcmp(streamCardId, currentMixerData->streamCardId))))
return currentMixerData;
currentMixerData = currentMixerData->next;