Disable SSP mode in headless device 53/180753/2
authorWootak Jung <wootak.jung@samsung.com>
Mon, 4 Jun 2018 00:58:33 +0000 (09:58 +0900)
committerWootak Jung <wootak.jung@samsung.com>
Mon, 4 Jun 2018 01:23:36 +0000 (10:23 +0900)
Change-Id: I873f64b49887825f5a079306b41a03961b22bbee

src/adapter.c

index e0bb748..b3bc958 100644 (file)
@@ -13725,8 +13725,14 @@ static void read_info_complete(uint8_t status, uint16_t length,
 
        switch (main_opts.mode) {
        case BT_MODE_DUAL:
-               if (missing_settings & MGMT_SETTING_SSP)
-                       set_mode(adapter, MGMT_OP_SET_SSP, 0x01);
+               if (missing_settings & MGMT_SETTING_SSP) {
+#ifdef TIZEN_FEATURE_BLUEZ_MODIFY
+                       if (main_opts.pin_code)
+                               set_mode(adapter, MGMT_OP_SET_SSP, 0x00);
+                       else
+#endif
+                               set_mode(adapter, MGMT_OP_SET_SSP, 0x01);
+               }
                if (missing_settings & MGMT_SETTING_LE)
                        set_mode(adapter, MGMT_OP_SET_LE, 0x01);
                if (missing_settings & MGMT_SETTING_BREDR)