Implement RSSI scan filter
[platform/core/connectivity/bluetooth-frwk.git] / bt-oal / oal-hid-device.c
index 34e4863..62a93ef 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Open Adaptation Layer (OAL)
  *
- * Copyright (c) 2014-2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2019 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -48,8 +48,11 @@ static void connection_state_callback(bt_bdaddr_t *bd_addr, bthd_connection_stat
 
        BT_DBG("%d", state);
 
-       if (!event)
+       if (!event) {
+               BT_ERR("event is NULL");
                return;
+       }
+
        memcpy(event->address.addr, bd_addr->address, BT_ADDRESS_BYTES_NUM);
 
        event->status = OAL_STATUS_SUCCESS;