Skip to content

Commit d9232b5

Browse files
committed
samples: net: mqtt: Align with SFM_CREATE_STATE API changes
From the upstream migration guide: The SMF_CREATE_STATE macro now always takes 5 arguments. The amount of arguments is now independent of the values of CONFIG_SMF_ANCESTOR_SUPPORT and CONFIG_SMF_INITIAL_TRANSITION. If the additional arguments are not used, they have to be set to NULL Signed-off-by: Robert Lubos <robert.lubos@nordicsemi.no>
1 parent 8cfc88d commit d9232b5

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

samples/net/mqtt/src/modules/transport/transport.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -299,8 +299,10 @@ static void connected_exit(void *o)
299299

300300
/* Construct state table */
301301
static const struct smf_state state[] = {
302-
[MQTT_DISCONNECTED] = SMF_CREATE_STATE(disconnected_entry, disconnected_run, NULL),
303-
[MQTT_CONNECTED] = SMF_CREATE_STATE(connected_entry, connected_run, connected_exit),
302+
[MQTT_DISCONNECTED] = SMF_CREATE_STATE(disconnected_entry, disconnected_run, NULL,
303+
NULL, NULL),
304+
[MQTT_CONNECTED] = SMF_CREATE_STATE(connected_entry, connected_run, connected_exit,
305+
NULL, NULL),
304306
};
305307

306308
static void transport_task(void)

0 commit comments

Comments
 (0)