87f2283286
- Backport upstream fixes: A couple of USB-audio config addition/fix, dmix PCM stop fix, a memory leak fix, DSD format endianess fix, PCM timestamp fixes, etc. 0050-USB-Audio-Add-Scarlett-2i4-USB-to-S-PDIF-blacklist.patch 0051-snd_user_file-fix-memory-leak.patch 0052-pcm-dmix-Don-t-ignore-SND_TIMER_EVENT_MSTOP.patch 0053-snd_dlsym-only-do-versioning-checks-if-built-with-ve.patch 0054-dlmisc-Remove-unused-label.patch 0055-USB-audio-Add-five-more-cards-to-IEC958-blacklist.patch 0056-pcm-Fix-DSD-sample-format-endianess-and-add-big-endi.patch 0057-mixer-Fix-inclusion-of-config.h.patch 0058-mixer-Fix-unused-parameter-warnings.patch 0059-ucm-Fix-uninitialized-err-in-snd_use_case_set.patch 0060-pcm-Fix-assorted-tstamp_type-bugs-omissions.patch OBS-URL: https://build.opensuse.org/request/show/264171 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/alsa?expand=0&rev=174
43 lines
1.3 KiB
Diff
43 lines
1.3 KiB
Diff
From 72c8b07b2a514261c2cb28558307b5fcb017b05e Mon Sep 17 00:00:00 2001
|
|
From: Takashi Iwai <tiwai@suse.de>
|
|
Date: Fri, 21 Nov 2014 15:25:30 +0100
|
|
Subject: [PATCH 59/60] ucm: Fix uninitialized err in snd_use_case_set()
|
|
|
|
The compiler warns like:
|
|
main.c:1664:9: warning: 'err' may be used uninitialized in this function [-Wmaybe-uninitialized]
|
|
|
|
and actually there are slight code paths that slip.
|
|
This patch adds the proper initializations to 0 to return the success
|
|
code in these code paths.
|
|
|
|
Signed-off-by: Takashi Iwai <tiwai@suse.de>
|
|
---
|
|
src/ucm/main.c | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/src/ucm/main.c b/src/ucm/main.c
|
|
index 049472827121..37ae4c84aa64 100644
|
|
--- a/src/ucm/main.c
|
|
+++ b/src/ucm/main.c
|
|
@@ -1443,7 +1443,7 @@ static int set_verb_user(snd_use_case_mgr_t *uc_mgr,
|
|
const char *verb_name)
|
|
{
|
|
struct use_case_verb *verb;
|
|
- int err;
|
|
+ int err = 0;
|
|
|
|
if (uc_mgr->active_verb &&
|
|
strcmp(uc_mgr->active_verb->name, verb_name) == 0)
|
|
@@ -1625,7 +1625,7 @@ int snd_use_case_set(snd_use_case_mgr_t *uc_mgr,
|
|
const char *value)
|
|
{
|
|
char *str, *str1;
|
|
- int err;
|
|
+ int err = 0;
|
|
|
|
pthread_mutex_lock(&uc_mgr->mutex);
|
|
if (strcmp(identifier, "_verb") == 0)
|
|
--
|
|
2.1.3
|
|
|