Neels Hofmeyr has submitted this change and it was merged.

Change subject: add ';' after OSMO_ASSERT()
......................................................................


add ';' after OSMO_ASSERT()

Currently, OSMO_ASSERT() is defined such that it ends in a semicolon, hence an
added ';' is redundant. However, the usual way this kind of macro should be
defined is

  #define OSMO_ASSERT(x) do { ... } while(0)

so that the compiler requires a trailing semicolon.

To prepare for such a change possibly coming up in libosmocore, add ';' to all
OSMO_ASSERT() users.

Change-Id: If6dce81faee9177737a6e1b572a871aaf7e37138
---
M src/osmo-bsc_nat/bsc_nat_utils.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/osmo-bsc_nat/bsc_nat_utils.c b/src/osmo-bsc_nat/bsc_nat_utils.c
index a9906b9..3094bbd 100644
--- a/src/osmo-bsc_nat/bsc_nat_utils.c
+++ b/src/osmo-bsc_nat/bsc_nat_utils.c
@@ -206,7 +206,7 @@
        llist_del(&cfg->entry);
        rate_ctr_group_free(cfg->stats.ctrg);
        cfg->nat->num_bsc--;
-       OSMO_ASSERT(cfg->nat->num_bsc >= 0)
+       OSMO_ASSERT(cfg->nat->num_bsc >= 0);
        talloc_free(cfg);
 }
 

-- 
To view, visit https://gerrit.osmocom.org/4142
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: If6dce81faee9177737a6e1b572a871aaf7e37138
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <[email protected]>
Gerrit-Reviewer: Harald Welte <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <[email protected]>

Reply via email to