service: add adapter powered check before connecting
authorArchie Pusaka <apusaka@chromium.org>
Thu, 5 Nov 2020 06:40:32 +0000 (14:40 +0800)
committerAyush Garg <ayush.garg@samsung.com>
Fri, 11 Mar 2022 13:38:33 +0000 (19:08 +0530)
commit411def40ba4101f9d8f0b62bedcd77e5e6c691e8
tree4b49453f5b9a558afd2cf64bd9a2de8f59526fad
parente907722fc8fdf0cfa8169650df62a010f97438a8
service: add adapter powered check before connecting

When policy_connect() is called, there might be a case where the
power is just turned off, hence the adapter is down. Add a check in
btd_service_connect to detect such condition.

Signed-off-by: Anuj Jain <anuj01.jain@samsung.com>
Signed-off-by: Ayush Garg <ayush.garg@samsung.com>
src/service.c