Remove unnecessary hs->sco check

The headset_request_stream function already handles the PLAYING state in
the beginning so hs->sco is guaranteed to be NULL later on.
This commit is contained in:
Johan Hedberg 2009-06-30 14:40:37 +03:00
parent 65aaf349eb
commit 894019b324

View File

@ -2305,10 +2305,8 @@ unsigned int headset_request_stream(struct audio_device *dev,
if (rfcomm_connect(dev, cb, user_data, &id) < 0)
return 0;
hs->auto_dc = TRUE;
} else if (hs->sco == NULL) {
if (sco_connect(dev, cb, user_data, &id) < 0)
return 0;
}
} else if (sco_connect(dev, cb, user_data, &id) < 0)
return 0;
hs->pending->target_state = HEADSET_STATE_PLAYING;