From 61219c26e21f5e648c1010a68a1c057c7b42afa7 Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Wed, 3 Oct 2012 22:18:36 +0300 Subject: [PATCH] core: Fix return value for external profile SDP function --- src/profile.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/profile.c b/src/profile.c index 47e3eb02f..11bc05866 100644 --- a/src/profile.c +++ b/src/profile.c @@ -777,12 +777,10 @@ static int resolve_service(struct ext_io *conn, bdaddr_t *src, bdaddr_t *dst) bt_string2uuid(&uuid, ext->remote_uuids[0]); err = bt_search_service(src, dst, &uuid, record_cb, conn, NULL); - if (err < 0) - return err; - - conn->resolving = true; + if (err == 0) + conn->resolving = true; - return -ENOSYS; + return err; } static int ext_connect_dev(struct btd_device *dev, struct btd_profile *profile, -- 2.47.3