mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
audio: return Error ** from audio_state_by_name
Remove duplicate error formatting code. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
parent
f6061733a9
commit
176adafca7
6 changed files with 13 additions and 20 deletions
3
ui/vnc.c
3
ui/vnc.c
|
@ -4181,9 +4181,8 @@ void vnc_display_open(const char *id, Error **errp)
|
|||
|
||||
audiodev = qemu_opt_get(opts, "audiodev");
|
||||
if (audiodev) {
|
||||
vd->audio_state = audio_state_by_name(audiodev);
|
||||
vd->audio_state = audio_state_by_name(audiodev, errp);
|
||||
if (!vd->audio_state) {
|
||||
error_setg(errp, "Audiodev '%s' not found", audiodev);
|
||||
goto fail;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue