diff options
Diffstat (limited to 'audio/manager.c')
| -rw-r--r-- | audio/manager.c | 11 | 
1 files changed, 5 insertions, 6 deletions
| diff --git a/audio/manager.c b/audio/manager.c index cb241d76..d824548e 100644 --- a/audio/manager.c +++ b/audio/manager.c @@ -464,12 +464,11 @@ static void auth_cb(DBusError *derr, void *user_data)  	} else {  		char hs_address[18]; -		headset_set_authorized(device); -  		ba2str(&device->dst, hs_address); -  		debug("Accepted headset connection from %s for %s",  						hs_address, device->path); + +		headset_set_authorized(device);  	}  } @@ -510,16 +509,16 @@ static void ag_io_cb(GIOChannel *chan, int err, const bdaddr_t *src,  		goto drop;  	} +	headset_set_state(device, HEADSET_STATE_CONNECT_IN_PROGRESS); +  	err = btd_request_authorization(&device->src, &device->dst, uuid,  				auth_cb, device);  	if (err < 0) {  		debug("Authorization denied: %s", strerror(-err)); -		headset_close_rfcomm(device); +		headset_set_state(device, HEADSET_STATE_DISCONNECTED);  		return;  	} -	headset_set_state(device, HEADSET_STATE_CONNECT_IN_PROGRESS); -  	return;  drop: | 
