From 718750f962099621180f1fde2fefb845c59d97d6 Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Wed, 6 Jul 2022 08:05:26 -0400 Subject: [PATCH] fs/testsuite: add mising braces to single line if statements Following zephyr's style guideline, all if statements, including single line statements shall have braces. Signed-off-by: Anas Nashif --- subsys/fs/fs.c | 3 ++- subsys/testsuite/ztest/src/ztest_mock.c | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/subsys/fs/fs.c b/subsys/fs/fs.c index 687c5f0bee8..91aedc1af2d 100644 --- a/subsys/fs/fs.c +++ b/subsys/fs/fs.c @@ -121,8 +121,9 @@ static int fs_get_mnt_point(struct fs_mount_t **mnt_pntp, } *mnt_pntp = mnt_p; - if (match_len) + if (match_len) { *match_len = mnt_p->mountp_len; + } return 0; } diff --git a/subsys/testsuite/ztest/src/ztest_mock.c b/subsys/testsuite/ztest/src/ztest_mock.c index 6f2fbdd91db..4ed369eb440 100644 --- a/subsys/testsuite/ztest/src/ztest_mock.c +++ b/subsys/testsuite/ztest/src/ztest_mock.c @@ -106,8 +106,9 @@ static void free_parameter(struct parameter *param) { unsigned int allocation_index = param - params; - if (param == NULL) + if (param == NULL) { return; + } __ASSERT(allocation_index < CONFIG_ZTEST_PARAMETER_COUNT, "param %p given to free is not in the static buffer %p:%u", param, params, CONFIG_ZTEST_PARAMETER_COUNT);