summaryrefslogtreecommitdiff
path: root/alsactl
diff options
context:
space:
mode:
authorRosen Penev <rosenp@gmail.com>2019-11-19 20:28:55 -0800
committerTakashi Iwai <tiwai@suse.de>2019-11-20 19:46:17 +0100
commit80fd81f4a8647fe2b62a02db9a497d2a7639d9e3 (patch)
tree853d641088d9bf8095b1797b936d8dc77bdb7ba6 /alsactl
parent66e9a816093c7d8fbdfbc407062daabe89825b35 (diff)
downloadalsa-utils-80fd81f4a8647fe2b62a02db9a497d2a7639d9e3.tar.gz
treewide: Fix printf formats
Found with cppcheck Signed-off-by: Rosen Penev <rosenp@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'alsactl')
-rw-r--r--alsactl/init_parse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/alsactl/init_parse.c b/alsactl/init_parse.c
index 562e674..c048fd3 100644
--- a/alsactl/init_parse.c
+++ b/alsactl/init_parse.c
@@ -187,7 +187,7 @@ static int init_space(struct space **space, int card)
return -ENOMEM;
res->ctl_id_changed = ~0;
res->linenum = -1;
- sprintf(device, "hw:%u", card);
+ sprintf(device, "hw:%d", card);
err = snd_hctl_open(&res->ctl_handle, device, 0);
if (err < 0)
goto error;
@@ -734,7 +734,7 @@ dbvalue:
elem = snd_hctl_elem_next(elem);
}
snd_ctl_elem_id_free(id);
- sprintf(res, "%u", index);
+ sprintf(res, "%d", index);
dbg("do_ctl_count found %s controls", res);
return res;
}