core/service: Add btd_service_set_blocked
authorLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Sat, 8 Feb 2014 11:49:50 +0000 (13:49 +0200)
committerMikko Ylinen <mikko.ylinen@intel.com>
Tue, 23 Sep 2014 18:29:21 +0000 (21:29 +0300)
src/service.c
src/service.h

index c6c7a885f5ab56eda008f36a433bb5a306f43147..ec1ee67795d5e3760090b6e112d4d6cc63ecc31e 100644 (file)
@@ -56,6 +56,7 @@ struct btd_service {
        btd_service_state_t     state;
        int                     err;
        bool                    auto_connect;
+       bool                    blocked;
 };
 
 struct service_state_callback {
@@ -321,6 +322,11 @@ bool btd_service_get_auto_connect(const struct btd_service *service)
        return service->auto_connect;
 }
 
+void btd_service_set_blocked(struct btd_service *service, bool value)
+{
+       service->blocked = value;
+}
+
 unsigned int btd_service_add_state_cb(btd_service_state_cb cb, void *user_data)
 {
        struct service_state_callback *state_cb;
index 105240b60cf7c600bb08b3bf5f0ff6a5130177bb..686e51c9a4ccc043d7d14a65d163190c72010fee 100644 (file)
@@ -62,6 +62,8 @@ uint16_t btd_service_get_version(const struct btd_service *service);
 void btd_service_set_auto_connect(struct btd_service *service, bool value);
 bool btd_service_get_auto_connect(const struct btd_service *service);
 
+void btd_service_set_blocked(struct btd_service *service, bool value);
+
 unsigned int btd_service_add_state_cb(btd_service_state_cb cb,
                                                        void *user_data);
 bool btd_service_remove_state_cb(unsigned int id);