OSDN Git Service

Fix macro for maximum allowed HOGP devices
authorNitin Arora <niarora@codeaurora.org>
Mon, 10 Mar 2014 20:25:27 +0000 (13:25 -0700)
committerNitin Arora <niarora@codeaurora.org>
Fri, 27 Mar 2015 00:38:26 +0000 (17:38 -0700)
This checks HOGP dev handle count less than or equal to maximum
allowed HOGP devices.

Change-Id: I63e6c3bc64a8c305b739b5eade0e846315e1ad1d

bta/hh/bta_hh_int.h

index aaf9461..2db0cf1 100644 (file)
@@ -233,7 +233,7 @@ typedef struct
 #define BTA_HH_GET_LE_DEV_HDL(x)        (UINT8)(((x)  + 1) << 4)
 /* check to see if th edevice handle is a LE device handle */
 #define BTA_HH_IS_LE_DEV_HDL(x)        ((x) & 0xf0)
-#define BTA_HH_IS_LE_DEV_HDL_VALID(x)  (((x)>>4) < BTA_HH_LE_MAX_KNOWN)
+#define BTA_HH_IS_LE_DEV_HDL_VALID(x)  (((x)>>4) <= BTA_HH_LE_MAX_KNOWN)
 #endif
 
 /* device control block */