From 60e90bcc4d46b26ec056821f3024b08d364f1cc7 Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Wed, 6 Jun 2007 09:24:37 +0000 Subject: Another minor fix --- audio/headset.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'audio/headset.c') diff --git a/audio/headset.c b/audio/headset.c index b58aa903..5fc33c43 100644 --- a/audio/headset.c +++ b/audio/headset.c @@ -447,7 +447,7 @@ failed: static gboolean rfcomm_connect_cb(GIOChannel *chan, GIOCondition cond, audio_device_t *device) { - struct headset *hs = device->headset; + struct headset *hs; char hs_address[18]; int sk, ret, err; socklen_t len; @@ -455,6 +455,8 @@ static gboolean rfcomm_connect_cb(GIOChannel *chan, GIOCondition cond, if (cond & G_IO_NVAL) return FALSE; + hs = device->headset; + assert(hs != NULL); assert(hs->pending_connect != NULL); assert(hs->rfcomm == NULL); -- cgit