aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--audio/audio.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/audio/audio.c b/audio/audio.c
index 0fdb808..b48471b 100644
--- a/audio/audio.c
+++ b/audio/audio.c
@@ -1684,7 +1684,9 @@ static AudioState *audio_init(Audiodev *dev, const char *name)
* backend and this can go away.
*/
driver = audio_driver_lookup("spice");
- driver->can_be_default = 1;
+ if (driver) {
+ driver->can_be_default = 1;
+ }
}
if (dev) {