diff --git a/spa/plugins/bluez5/backend-native.c b/spa/plugins/bluez5/backend-native.c index 3f1b3ae84..7c5fcefa8 100644 --- a/spa/plugins/bluez5/backend-native.c +++ b/spa/plugins/bluez5/backend-native.c @@ -2759,13 +2759,13 @@ static void sco_ready(struct spa_bt_transport *t) } /* Clear nonblocking flag we set for connect() */ - err = fcntl(t->fd, F_GETFL, O_NONBLOCK); + err = fcntl(t->fd, F_GETFL); if (err < 0) { td->err = -errno; goto done; } err &= ~O_NONBLOCK; - err = fcntl(t->fd, F_SETFL, O_NONBLOCK, err); + err = fcntl(t->fd, F_SETFL, err); if (err < 0) { td->err = -errno; goto done;