From 6ae04b357f83d5e932b2e088c2fb13168d9b9b60 Mon Sep 17 00:00:00 2001 From: Szymon Janc Date: Thu, 19 Sep 2013 16:00:41 +0200 Subject: [PATCH] adapter: Insert DeviceID record if setting DeviceID data to controller DeviceID is special since its record is registered on start by sdpd-server and always has handle 0x10000. --- src/adapter.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/adapter.c b/src/adapter.c index 5434a0744..7c4414572 100644 --- a/src/adapter.c +++ b/src/adapter.c @@ -5622,9 +5622,13 @@ static int adapter_register(struct btd_adapter *adapter) adapter->initialized = TRUE; - if (main_opts.did_source) + if (main_opts.did_source) { + /* DeviceID record is added by sdpd-server before any other + * record is registered. */ + adapter_service_insert(adapter, sdp_record_find(0x10000)); set_did(adapter, main_opts.did_vendor, main_opts.did_product, main_opts.did_version, main_opts.did_source); + } DBG("Adapter %s registered", adapter->path); -- 2.11.0