Skip to content

Commit

Permalink
alsactl: info - print errors for next_device calls
Browse files Browse the repository at this point in the history
Signed-off-by: Jaroslav Kysela <[email protected]>
  • Loading branch information
perexg committed Jan 9, 2025
1 parent 4efe03b commit 258d649
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions alsactl/info.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ static int pcm_device_list(snd_ctl_t *ctl, snd_pcm_stream_t stream, bool *first)
streamfirst = true;
while (1) {
if ((err = snd_ctl_pcm_next_device(ctl, &dev)) < 0) {
error("snd_ctl_pcm_next_device");
error("snd_ctl_pcm_next_device: %s", snd_strerror(err));
return err;
}
if (dev < 0)
Expand Down Expand Up @@ -102,7 +102,7 @@ static int rawmidi_device_list(snd_ctl_t *ctl, snd_rawmidi_stream_t stream, bool
streamfirst = true;
while (1) {
if ((err = snd_ctl_rawmidi_next_device(ctl, &dev)) < 0) {
error("snd_ctl_rawmidi_next_device");
error("snd_ctl_rawmidi_next_device: %s", snd_strerror(err));
return err;
}
if (dev < 0)
Expand Down

0 comments on commit 258d649

Please sign in to comment.