state_machine: Convert Boolean to C99 bool
Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
This commit is contained in:
parent
0365458eb8
commit
f75a0339d5
1 changed files with 4 additions and 4 deletions
|
@ -9,7 +9,7 @@
|
||||||
* implement a state machine. In addition to including this header file, each
|
* implement a state machine. In addition to including this header file, each
|
||||||
* file implementing a state machine must define STATE_MACHINE_DATA to be the
|
* file implementing a state machine must define STATE_MACHINE_DATA to be the
|
||||||
* data structure including state variables (enum machine_state,
|
* data structure including state variables (enum machine_state,
|
||||||
* Boolean changed), and STATE_MACHINE_DEBUG_PREFIX to be a string that is used
|
* bool changed), and STATE_MACHINE_DEBUG_PREFIX to be a string that is used
|
||||||
* as a prefix for all debug messages. If SM_ENTRY_MA macro is used to define
|
* as a prefix for all debug messages. If SM_ENTRY_MA macro is used to define
|
||||||
* a group of state machines with shared data structure, STATE_MACHINE_ADDR
|
* a group of state machines with shared data structure, STATE_MACHINE_ADDR
|
||||||
* needs to be defined to point to the MAC address used in debug output.
|
* needs to be defined to point to the MAC address used in debug output.
|
||||||
|
@ -45,7 +45,7 @@ static void sm_ ## machine ## _ ## state ## _Enter(STATE_MACHINE_DATA *sm, \
|
||||||
*/
|
*/
|
||||||
#define SM_ENTRY(machine, state) \
|
#define SM_ENTRY(machine, state) \
|
||||||
if (!global || sm->machine ## _state != machine ## _ ## state) { \
|
if (!global || sm->machine ## _state != machine ## _ ## state) { \
|
||||||
sm->changed = TRUE; \
|
sm->changed = true; \
|
||||||
wpa_printf(MSG_DEBUG, STATE_MACHINE_DEBUG_PREFIX ": " #machine \
|
wpa_printf(MSG_DEBUG, STATE_MACHINE_DEBUG_PREFIX ": " #machine \
|
||||||
" entering state " #state); \
|
" entering state " #state); \
|
||||||
} \
|
} \
|
||||||
|
@ -64,7 +64,7 @@ sm->machine ## _state = machine ## _ ## state;
|
||||||
*/
|
*/
|
||||||
#define SM_ENTRY_M(machine, _state, data) \
|
#define SM_ENTRY_M(machine, _state, data) \
|
||||||
if (!global || sm->data ## _ ## state != machine ## _ ## _state) { \
|
if (!global || sm->data ## _ ## state != machine ## _ ## _state) { \
|
||||||
sm->changed = TRUE; \
|
sm->changed = true; \
|
||||||
wpa_printf(MSG_DEBUG, STATE_MACHINE_DEBUG_PREFIX ": " \
|
wpa_printf(MSG_DEBUG, STATE_MACHINE_DEBUG_PREFIX ": " \
|
||||||
#machine " entering state " #_state); \
|
#machine " entering state " #_state); \
|
||||||
} \
|
} \
|
||||||
|
@ -82,7 +82,7 @@ sm->data ## _ ## state = machine ## _ ## _state;
|
||||||
*/
|
*/
|
||||||
#define SM_ENTRY_MA(machine, _state, data) \
|
#define SM_ENTRY_MA(machine, _state, data) \
|
||||||
if (!global || sm->data ## _ ## state != machine ## _ ## _state) { \
|
if (!global || sm->data ## _ ## state != machine ## _ ## _state) { \
|
||||||
sm->changed = TRUE; \
|
sm->changed = true; \
|
||||||
wpa_printf(MSG_DEBUG, STATE_MACHINE_DEBUG_PREFIX ": " MACSTR " " \
|
wpa_printf(MSG_DEBUG, STATE_MACHINE_DEBUG_PREFIX ": " MACSTR " " \
|
||||||
#machine " entering state " #_state, \
|
#machine " entering state " #_state, \
|
||||||
MAC2STR(STATE_MACHINE_ADDR)); \
|
MAC2STR(STATE_MACHINE_ADDR)); \
|
||||||
|
|
Loading…
Reference in a new issue