diff --git a/nimble/host/src/ble_att.c b/nimble/host/src/ble_att.c index a517bd36e..31b278a75 100644 --- a/nimble/host/src/ble_att.c +++ b/nimble/host/src/ble_att.c @@ -22,11 +22,11 @@ #include "ble_hs_priv.h" #ifndef min -#define min(a, b) ((a)<(b)?(a):(b)) +#define min(a, b) ((a) < (b) ? (a) : (b)) #endif #ifndef max -#define max(a, b) ((a)>(b)?(a):(b)) +#define max(a, b) ((a) > (b) ? (a) : (b)) #endif static uint16_t ble_att_preferred_mtu_val; diff --git a/nimble/host/src/ble_gap.c b/nimble/host/src/ble_gap.c index 76168a1d7..ab1771ff7 100644 --- a/nimble/host/src/ble_gap.c +++ b/nimble/host/src/ble_gap.c @@ -27,11 +27,11 @@ #include "ble_hs_resolv_priv.h" #ifndef min -#define min(a, b) ((a)<(b)?(a):(b)) +#define min(a, b) ((a) < (b) ? (a) : (b)) #endif #ifndef max -#define max(a, b) ((a)>(b)?(a):(b)) +#define max(a, b) ((a) > (b) ? (a) : (b)) #endif #if MYNEWT diff --git a/nimble/host/src/ble_gattc.c b/nimble/host/src/ble_gattc.c index b4731e153..13f53336f 100644 --- a/nimble/host/src/ble_gattc.c +++ b/nimble/host/src/ble_gattc.c @@ -61,11 +61,11 @@ #include "ble_hs_priv.h" #ifndef min -#define min(a, b) ((a)<(b)?(a):(b)) +#define min(a, b) ((a) < (b) ? (a) : (b)) #endif #ifndef max -#define max(a, b) ((a)>(b)?(a):(b)) +#define max(a, b) ((a) > (b) ? (a) : (b)) #endif /***************************************************************************** diff --git a/nimble/host/src/ble_hs_hci_util.c b/nimble/host/src/ble_hs_hci_util.c index ef993f390..e0e535b9e 100644 --- a/nimble/host/src/ble_hs_hci_util.c +++ b/nimble/host/src/ble_hs_hci_util.c @@ -23,11 +23,11 @@ #include "ble_hs_priv.h" #ifndef min -#define min(a, b) ((a)<(b)?(a):(b)) +#define min(a, b) ((a) < (b) ? (a) : (b)) #endif #ifndef max -#define max(a, b) ((a)>(b)?(a):(b)) +#define max(a, b) ((a) > (b) ? (a) : (b)) #endif uint16_t diff --git a/nimble/host/src/ble_sm.c b/nimble/host/src/ble_sm.c index 328fdec58..b643653ce 100644 --- a/nimble/host/src/ble_sm.c +++ b/nimble/host/src/ble_sm.c @@ -51,11 +51,11 @@ #include "../store/config/src/ble_store_config_priv.h" #ifndef min -#define min(a, b) ((a)<(b)?(a):(b)) +#define min(a, b) ((a) < (b) ? (a) : (b)) #endif #ifndef max -#define max(a, b) ((a)>(b)?(a):(b)) +#define max(a, b) ((a) > (b) ? (a) : (b)) #endif #if NIMBLE_BLE_SM diff --git a/porting/nimble/src/os_mbuf.c b/porting/nimble/src/os_mbuf.c index 307d83bb5..38ab01525 100644 --- a/porting/nimble/src/os_mbuf.c +++ b/porting/nimble/src/os_mbuf.c @@ -41,11 +41,11 @@ #include #ifndef min -#define min(a, b) ((a)<(b)?(a):(b)) +#define min(a, b) ((a) < (b) ? (a) : (b)) #endif #ifndef max -#define max(a, b) ((a)>(b)?(a):(b)) +#define max(a, b) ((a) > (b) ? (a) : (b)) #endif /**