]> git.proxmox.com Git - mirror_frr.git/commitdiff
*: require semicolon after DEFINE_<typesafe...>
authorDavid Lamparter <equinox@diac24.net>
Sun, 21 Feb 2021 05:54:16 +0000 (06:54 +0100)
committerDavid Lamparter <equinox@diac24.net>
Wed, 17 Mar 2021 05:18:39 +0000 (06:18 +0100)
Again, see previous commits.

Signed-off-by: David Lamparter <equinox@diac24.net>
44 files changed:
bgpd/bgp_advertise.h
bgpd/bgp_bmp.c
bgpd/bgp_bmp.h
bgpd/bgp_labelpool.c
bgpd/bgp_labelpool.h
doc/developer/lists.rst
isisd/isis_lfa.h
isisd/isis_lsp.h
isisd/isis_sr.c
isisd/isis_sr.h
lib/atomlist.h
lib/debug.c
lib/debug.h
lib/elf_py.c
lib/frrcu.c
lib/frrcu.h
lib/link_state.h
lib/qobj.c
lib/qobj.h
lib/table.c
lib/table.h
lib/thread.c
lib/thread.h
lib/typerb.h
lib/typesafe.h
lib/zlog.h
ospf6d/ospf6_spf.c
ospf6d/ospf6_spf.h
ospfd/ospf_spf.c
ospfd/ospf_spf.h
ospfd/ospf_ti_lfa.c
ospfd/ospfd.c
ospfd/ospfd.h
pathd/path_pcep_pcc.c
pathd/path_pcep_pcc.h
pimd/pim_oil.h
pimd/pim_upstream.h
tests/lib/cxxcompat.c
tests/lib/test_atomlist.c
tests/lib/test_typelist.h
tests/ospfd/test_ospf_spf.c
vtysh/vtysh_config.c
zebra/rib.h
zebra/zebra_vrf.h

index 745a0dffce2c1a9daf7868e7051ec04b315b4389..ef4f626111958fcde21b455904ddaa7741904a13 100644 (file)
@@ -23,7 +23,7 @@
 
 #include "lib/typesafe.h"
 
-PREDECL_DLIST(bgp_adv_fifo)
+PREDECL_DLIST(bgp_adv_fifo);
 
 struct update_subgroup;
 
@@ -60,7 +60,7 @@ struct bgp_advertise {
        struct bgp_path_info *pathi;
 };
 
-DECLARE_DLIST(bgp_adv_fifo, struct bgp_advertise, fifo)
+DECLARE_DLIST(bgp_adv_fifo, struct bgp_advertise, fifo);
 
 /* BGP adjacency out.  */
 struct bgp_adj_out {
index f733042f7ede1c596a0896ae788b09a493411f34..4710a9a3f7b2ac76b14f08138a8fb077fd5c88f5 100644 (file)
@@ -89,7 +89,7 @@ static uint32_t bmp_bgp_hash(const struct bmp_bgp *e)
        return jhash(&e->bgp, sizeof(e->bgp), 0x55aa5a5a);
 }
 
-DECLARE_HASH(bmp_bgph, struct bmp_bgp, bbi, bmp_bgp_cmp, bmp_bgp_hash)
+DECLARE_HASH(bmp_bgph, struct bmp_bgp, bbi, bmp_bgp_cmp, bmp_bgp_hash);
 
 struct bmp_bgph_head bmp_bgph;
 
@@ -109,11 +109,11 @@ static uint32_t bmp_bgp_peer_hash(const struct bmp_bgp_peer *e)
 }
 
 DECLARE_HASH(bmp_peerh, struct bmp_bgp_peer, bpi,
-               bmp_bgp_peer_cmp, bmp_bgp_peer_hash)
+               bmp_bgp_peer_cmp, bmp_bgp_peer_hash);
 
 struct bmp_peerh_head bmp_peerh;
 
-DECLARE_LIST(bmp_mirrorq, struct bmp_mirrorq, bmi)
+DECLARE_LIST(bmp_mirrorq, struct bmp_mirrorq, bmi);
 
 /* listener management */
 
@@ -132,7 +132,8 @@ static int bmp_listener_cmp(const struct bmp_listener *a,
        return 0;
 }
 
-DECLARE_SORTLIST_UNIQ(bmp_listeners, struct bmp_listener, bli, bmp_listener_cmp)
+DECLARE_SORTLIST_UNIQ(bmp_listeners, struct bmp_listener, bli,
+                     bmp_listener_cmp);
 
 static int bmp_targets_cmp(const struct bmp_targets *a,
                           const struct bmp_targets *b)
@@ -140,11 +141,11 @@ static int bmp_targets_cmp(const struct bmp_targets *a,
        return strcmp(a->name, b->name);
 }
 
-DECLARE_SORTLIST_UNIQ(bmp_targets, struct bmp_targets, bti, bmp_targets_cmp)
+DECLARE_SORTLIST_UNIQ(bmp_targets, struct bmp_targets, bti, bmp_targets_cmp);
 
-DECLARE_LIST(bmp_session, struct bmp, bsi)
+DECLARE_LIST(bmp_session, struct bmp, bsi);
 
-DECLARE_DLIST(bmp_qlist, struct bmp_queue_entry, bli)
+DECLARE_DLIST(bmp_qlist, struct bmp_queue_entry, bli);
 
 static int bmp_qhash_cmp(const struct bmp_queue_entry *a,
                const struct bmp_queue_entry *b)
@@ -189,7 +190,7 @@ static uint32_t bmp_qhash_hkey(const struct bmp_queue_entry *e)
 }
 
 DECLARE_HASH(bmp_qhash, struct bmp_queue_entry, bhi,
-               bmp_qhash_cmp, bmp_qhash_hkey)
+               bmp_qhash_cmp, bmp_qhash_hkey);
 
 static int bmp_active_cmp(const struct bmp_active *a,
                const struct bmp_active *b)
@@ -206,7 +207,7 @@ static int bmp_active_cmp(const struct bmp_active *a,
        return 0;
 }
 
-DECLARE_SORTLIST_UNIQ(bmp_actives, struct bmp_active, bai, bmp_active_cmp)
+DECLARE_SORTLIST_UNIQ(bmp_actives, struct bmp_active, bai, bmp_active_cmp);
 
 static struct bmp *bmp_new(struct bmp_targets *bt, int bmp_sock)
 {
index 10ca1e80fa0e34b3539ccdb872efdc0a0f6a31b3..899840e582de2e1cd2158ec24bf563a01049956d 100644 (file)
@@ -66,8 +66,8 @@
  * always happens from the front of the queue.)
  */
 
-PREDECL_DLIST(bmp_qlist)
-PREDECL_HASH(bmp_qhash)
+PREDECL_DLIST(bmp_qlist);
+PREDECL_HASH(bmp_qhash);
 
 struct bmp_queue_entry {
        struct bmp_qlist_item bli;
@@ -92,7 +92,7 @@ struct bmp_queue_entry {
  * with a size limit.  Refcount works the same as for monitoring above.
  */
 
-PREDECL_LIST(bmp_mirrorq)
+PREDECL_LIST(bmp_mirrorq);
 
 struct bmp_mirrorq {
        struct bmp_mirrorq_item bmi;
@@ -112,7 +112,7 @@ enum {
        BMP_AFI_LIVE,
 };
 
-PREDECL_LIST(bmp_session)
+PREDECL_LIST(bmp_session);
 
 struct bmp_active;
 struct bmp_targets;
@@ -166,7 +166,7 @@ struct bmp {
  * succeeds, "bmp" is set up.
  */
 
-PREDECL_SORTLIST_UNIQ(bmp_actives)
+PREDECL_SORTLIST_UNIQ(bmp_actives);
 
 #define BMP_DFLT_MINRETRY      30000
 #define BMP_DFLT_MAXRETRY      720000
@@ -191,7 +191,7 @@ struct bmp_active {
 };
 
 /* config & state for passive / listening sockets */
-PREDECL_SORTLIST_UNIQ(bmp_listeners)
+PREDECL_SORTLIST_UNIQ(bmp_listeners);
 
 struct bmp_listener {
        struct bmp_listeners_item bli;
@@ -209,7 +209,7 @@ struct bmp_listener {
  * bmp_active items.  If they have the same config, BMP session should be
  * put in the same targets since that's a bit more effective.
  */
-PREDECL_SORTLIST_UNIQ(bmp_targets)
+PREDECL_SORTLIST_UNIQ(bmp_targets);
 
 struct bmp_targets {
        struct bmp_targets_item bti;
@@ -251,7 +251,7 @@ DECLARE_QOBJ_TYPE(bmp_targets);
 
 /* per struct peer * data.  Lookup by peer->qobj_node.nid, created on demand,
  * deleted in peer_backward hook. */
-PREDECL_HASH(bmp_peerh)
+PREDECL_HASH(bmp_peerh);
 
 struct bmp_bgp_peer {
        struct bmp_peerh_item bpi;
@@ -267,7 +267,7 @@ struct bmp_bgp_peer {
 };
 
 /* per struct bgp * data */
-PREDECL_HASH(bmp_bgph)
+PREDECL_HASH(bmp_bgph);
 
 #define BMP_PEER_DOWN_NO_RELEVANT_EVENT_CODE 0x00
 
index 9a6cc10ae216f0e120b291faffb180d2f4ec26a4..fcb2df9d6f8f071b9d8ea71cf9ec797b5c95e33a 100644 (file)
@@ -80,7 +80,7 @@ struct lp_fifo {
        struct lp_lcb   lcb;
 };
 
-DECLARE_LIST(lp_fifo, struct lp_fifo, fifo)
+DECLARE_LIST(lp_fifo, struct lp_fifo, fifo);
 
 struct lp_cbq_item {
        int             (*cbfunc)(mpls_label_t label, void *lblid, bool alloc);
index d9f64acfe40002f25d4e87492c151cf83f8c8ce0..d6a8eec84d8d364b548c1552d38edf1600da5a4f 100644 (file)
@@ -31,7 +31,7 @@
 #define LP_TYPE_VRF    0x00000001
 #define LP_TYPE_BGP_LU 0x00000002
 
-PREDECL_LIST(lp_fifo)
+PREDECL_LIST(lp_fifo);
 
 struct labelpool {
        struct skiplist         *ledger;        /* all requests */
index 28b21533c0450f66f326b6a721720875a743d360..86db788c0e47766da8f90df8e50cb1702f8c9651 100644 (file)
@@ -140,7 +140,7 @@ The common setup pattern will look like this:
 
    #include <typesafe.h>
 
-   PREDECL_XXX(Z)
+   PREDECL_XXX(Z);
    struct item {
        int otherdata;
        struct Z_item mylistitem;
@@ -149,20 +149,20 @@ The common setup pattern will look like this:
    struct Z_head mylisthead;
 
    /* unsorted: */
-   DECLARE_XXX(Z, struct item, mylistitem)
+   DECLARE_XXX(Z, struct item, mylistitem);
 
    /* sorted, items that compare as equal cannot be added to list */
    int compare_func(const struct item *a, const struct item *b);
-   DECLARE_XXX_UNIQ(Z, struct item, mylistitem, compare_func)
+   DECLARE_XXX_UNIQ(Z, struct item, mylistitem, compare_func);
 
    /* sorted, items that compare as equal can be added to list */
    int compare_func(const struct item *a, const struct item *b);
-   DECLARE_XXX_NONUNIQ(Z, struct item, mylistitem, compare_func)
+   DECLARE_XXX_NONUNIQ(Z, struct item, mylistitem, compare_func);
 
    /* hash tables: */
    int compare_func(const struct item *a, const struct item *b);
    uint32_t hash_func(const struct item *a);
-   DECLARE_XXX(Z, struct item, mylistitem, compare_func, hash_func)
+   DECLARE_XXX(Z, struct item, mylistitem, compare_func, hash_func);
 
 ``XXX`` is replaced with the name of the data structure, e.g. ``SKIPLIST``
 or ``ATOMLIST``.  The ``DECLARE_XXX`` invocation can either occur in a `.h`
index 65891cae44313e81ed0f56fe1651facb6ca62d55..d75632e2cda64f2dfdbc8c69860d619dea07cffb 100644 (file)
@@ -23,8 +23,8 @@
 #include "lib/typesafe.h"
 #include "lib/zclient.h"
 
-PREDECL_RBTREE_UNIQ(lfa_tiebreaker_tree)
-PREDECL_RBTREE_UNIQ(rlfa_tree)
+PREDECL_RBTREE_UNIQ(lfa_tiebreaker_tree);
+PREDECL_RBTREE_UNIQ(rlfa_tree);
 
 enum lfa_tiebreaker_type {
        LFA_TIEBREAKER_DOWNSTREAM = 0,
@@ -41,7 +41,7 @@ struct lfa_tiebreaker {
 int lfa_tiebreaker_cmp(const struct lfa_tiebreaker *a,
                       const struct lfa_tiebreaker *b);
 DECLARE_RBTREE_UNIQ(lfa_tiebreaker_tree, struct lfa_tiebreaker, entry,
-                   lfa_tiebreaker_cmp)
+                   lfa_tiebreaker_cmp);
 
 struct rlfa {
        struct rlfa_tree_item entry;
@@ -50,7 +50,7 @@ struct rlfa {
        struct in_addr pq_address;
 };
 int rlfa_cmp(const struct rlfa *a, const struct rlfa *b);
-DECLARE_RBTREE_UNIQ(rlfa_tree, struct rlfa, entry, rlfa_cmp)
+DECLARE_RBTREE_UNIQ(rlfa_tree, struct rlfa, entry, rlfa_cmp);
 
 enum isis_tilfa_sid_type {
        TILFA_SID_PREFIX = 1,
index 896d9576072cf888407b56ea24cddcf1547c71d9..f3d9f61bcfa4955a3b26ef216d350241e57764da 100644 (file)
@@ -27,7 +27,7 @@
 #include "lib/typesafe.h"
 #include "isisd/isis_pdu.h"
 
-PREDECL_RBTREE_UNIQ(lspdb)
+PREDECL_RBTREE_UNIQ(lspdb);
 
 struct isis;
 /* Structure for isis_lsp, this structure will only support the fixed
@@ -61,7 +61,7 @@ struct isis_lsp {
 };
 
 extern int lspdb_compare(const struct isis_lsp *a, const struct isis_lsp *b);
-DECLARE_RBTREE_UNIQ(lspdb, struct isis_lsp, dbe, lspdb_compare)
+DECLARE_RBTREE_UNIQ(lspdb, struct isis_lsp, dbe, lspdb_compare);
 
 void lsp_db_init(struct lspdb_head *head);
 void lsp_db_fini(struct lspdb_head *head);
index 60ddf8e7e10ae3062dbfdb0a09c7300f5aaaa60a..c4024772f5c9d8988e8162bae17f53cb249b6a25 100644 (file)
@@ -73,7 +73,7 @@ static inline int sr_prefix_sid_cfg_compare(const struct sr_prefix_cfg *a,
        return prefix_cmp(&a->prefix, &b->prefix);
 }
 DECLARE_RBTREE_UNIQ(srdb_prefix_cfg, struct sr_prefix_cfg, entry,
-                   sr_prefix_sid_cfg_compare)
+                   sr_prefix_sid_cfg_compare);
 
 /**
  * Find SRGB associated to a System ID.
index b012dfb00a03e50a0ff9dfff44755074d801504c..a933f366eb729053f42270ba7f237092f31ed5a2 100644 (file)
@@ -57,7 +57,7 @@
 #define SRLB_UPPER_BOUND               15999
 
 /* Segment Routing Data Base (SRDB) RB-Tree structure */
-PREDECL_RBTREE_UNIQ(srdb_prefix_cfg)
+PREDECL_RBTREE_UNIQ(srdb_prefix_cfg);
 
 /*
  * Segment Routing Prefix-SID information.
index 5ca19cbcd4c7f21c8ada9c9225ca4e018f26e92f..c795128a34d5f56af5fb5b2fa2e49a3461ca2fb4 100644 (file)
@@ -123,15 +123,16 @@ struct atomlist_head {
 
 /* use as:
  *
- * PREDECL_ATOMLIST(namelist)
+ * PREDECL_ATOMLIST(namelist);
  * struct name {
  *   struct namelist_item nlitem;
  * }
- * DECLARE_ATOMLIST(namelist, struct name, nlitem)
+ * DECLARE_ATOMLIST(namelist, struct name, nlitem);
  */
 #define PREDECL_ATOMLIST(prefix)                                               \
 struct prefix ## _head { struct atomlist_head ah; };                           \
-struct prefix ## _item { struct atomlist_item ai; };
+struct prefix ## _item { struct atomlist_item ai; };                           \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_ATOMLIST(var) { }
 
@@ -171,7 +172,7 @@ macro_inline void prefix ## _fini(struct prefix##_head *h)                     \
        assert(prefix ## _count(h) == 0);                                      \
        memset(h, 0, sizeof(*h));                                              \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 /* add_head:
  * - contention on ->first pointer
@@ -221,7 +222,8 @@ struct atomsort_head {
 
 #define _PREDECL_ATOMSORT(prefix)                                              \
 struct prefix ## _head { struct atomsort_head ah; };                           \
-struct prefix ## _item { struct atomsort_item ai; };
+struct prefix ## _item { struct atomsort_item ai; };                           \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_ATOMSORT_UNIQ(var)                { }
 #define INIT_ATOMSORT_NONUNIQ(var)     { }
@@ -298,7 +300,7 @@ macro_inline type *prefix ## _pop(struct prefix##_head *h)                     \
        struct atomsort_item *p = atomsort_pop(&h->ah);                        \
        return p ? container_of(p, type, field.ai) : NULL;                     \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define PREDECL_ATOMSORT_UNIQ(prefix)                                          \
        _PREDECL_ATOMSORT(prefix)
@@ -312,7 +314,7 @@ macro_inline int prefix ## __cmp(const struct atomsort_item *a,                \
 }                                                                              \
                                                                                \
 _DECLARE_ATOMSORT(prefix, type, field,                                         \
-               prefix ## __cmp, prefix ## __cmp)                              \
+               prefix ## __cmp, prefix ## __cmp);                             \
                                                                                \
 atomic_find_warn                                                               \
 macro_inline type *prefix ## _find(struct prefix##_head *h, const type *item)  \
@@ -325,7 +327,7 @@ macro_inline type *prefix ## _find(struct prefix##_head *h, const type *item)  \
                return NULL;                                                   \
        return p;                                                              \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define PREDECL_ATOMSORT_NONUNIQ(prefix)                                       \
        _PREDECL_ATOMSORT(prefix)
@@ -352,8 +354,8 @@ macro_inline int prefix ## __cmp_uq(const struct atomsort_item *a,             \
 }                                                                              \
                                                                                \
 _DECLARE_ATOMSORT(prefix, type, field,                                         \
-               prefix ## __cmp, prefix ## __cmp_uq)                           \
-/* ... */
+               prefix ## __cmp, prefix ## __cmp_uq);                          \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 struct atomsort_item *atomsort_add(struct atomsort_head *h,
                struct atomsort_item *item, int (*cmpfn)(
index 3248ceb13b53222e84a143a5a532a73c4cf8d0dd..e2ba4cd4ef118fb9e47f2016788b254da509f0b7 100644 (file)
@@ -24,7 +24,7 @@
 
 static struct debug_cb_list_head cb_head;
 
-DECLARE_LIST(debug_cb_list, struct debug_callbacks, item)
+DECLARE_LIST(debug_cb_list, struct debug_callbacks, item);
 
 /* All code in this section should be reentrant and MT-safe */
 
index f25cd426913f8a0bb518df0e77b6e1933c6d060c..a72657bdafaf78d020a72f0c817a3aa9a0178f34 100644 (file)
@@ -84,7 +84,7 @@ struct debug {
        const char *desc;
 };
 
-PREDECL_LIST(debug_cb_list)
+PREDECL_LIST(debug_cb_list);
 /*
  * Callback set for debugging code.
  *
index 0d8ad76e1c4abb7f8016a2582b9fce56756da0bf..d26e443b82d9069c134a2c60d2bfe4aacf38641f 100644 (file)
@@ -100,7 +100,7 @@ static PyObject *refuse_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
 struct elfreloc;
 struct elfsect;
 
-PREDECL_HASH(elfrelocs)
+PREDECL_HASH(elfrelocs);
 
 /* ELFFile and ELFSection intentionally share some behaviour, particularly
  * subscript[123:456] access to file data.  This is because relocatables
@@ -200,7 +200,7 @@ static int elfreloc_cmp(const struct elfreloc *a, const struct elfreloc *b);
 static uint32_t elfreloc_hash(const struct elfreloc *reloc);
 
 DECLARE_HASH(elfrelocs, struct elfreloc, elfrelocs_item,
-            elfreloc_cmp, elfreloc_hash)
+            elfreloc_cmp, elfreloc_hash);
 
 static Elf_Scn *elf_find_addr(struct elffile *ef, uint64_t addr, size_t *idx);
 static PyObject *elffile_secbyidx(struct elffile *w, Elf_Scn *scn, size_t idx);
index c6c19bd56232873508597e7693542d16a81cfe59..0e717a98a5d98ad588f19b29e7c635368c758a75 100644 (file)
@@ -57,9 +57,9 @@
 DEFINE_MTYPE_STATIC(LIB, RCU_THREAD,    "RCU thread");
 DEFINE_MTYPE_STATIC(LIB, RCU_NEXT,      "RCU sequence barrier");
 
-DECLARE_ATOMLIST(rcu_heads, struct rcu_head, head)
+DECLARE_ATOMLIST(rcu_heads, struct rcu_head, head);
 
-PREDECL_ATOMLIST(rcu_threads)
+PREDECL_ATOMLIST(rcu_threads);
 struct rcu_thread {
        struct rcu_threads_item head;
 
@@ -70,7 +70,7 @@ struct rcu_thread {
        /* only accessed by thread itself, not atomic */
        unsigned depth;
 };
-DECLARE_ATOMLIST(rcu_threads, struct rcu_thread, head)
+DECLARE_ATOMLIST(rcu_threads, struct rcu_thread, head);
 
 static const struct rcu_action rcua_next  = { .type = RCUA_NEXT };
 static const struct rcu_action rcua_end   = { .type = RCUA_END };
index 47751ae7df395a01fd82b0c1ff6d53cd1597737a..38082590405ee887a4bd1618e14bca3f5c36349d 100644 (file)
@@ -116,7 +116,7 @@ struct rcu_action {
 };
 
 /* RCU cleanup function queue item */
-PREDECL_ATOMLIST(rcu_heads)
+PREDECL_ATOMLIST(rcu_heads);
 struct rcu_head {
        struct rcu_heads_item head;
        const struct rcu_action *action;
index 93669f5b234553e22d4dc9315ce095e5c924fd18..f9eb59b76a3409c4954adb063b299d03a3fa555f 100644 (file)
@@ -324,7 +324,7 @@ extern int ls_attributes_same(struct ls_attributes *a1,
  */
 
 /* Link State Vertex structure */
-PREDECL_RBTREE_UNIQ(vertices)
+PREDECL_RBTREE_UNIQ(vertices);
 struct ls_vertex {
        struct vertices_item entry;     /* Entry in RB Tree */
        uint64_t key;                   /* Unique Key identifier */
@@ -335,7 +335,7 @@ struct ls_vertex {
 };
 
 /* Link State Edge structure */
-PREDECL_RBTREE_UNIQ(edges)
+PREDECL_RBTREE_UNIQ(edges);
 struct ls_edge {
        struct edges_item entry;        /* Entry in RB tree */
        uint64_t key;                   /* Unique Key identifier */
@@ -345,7 +345,7 @@ struct ls_edge {
 };
 
 /* Link State Subnet structure */
-PREDECL_RBTREE_UNIQ(subnets)
+PREDECL_RBTREE_UNIQ(subnets);
 struct ls_subnet {
        struct subnets_item entry;      /* Entry in RB tree */
        struct prefix key;              /* Unique Key identifier */
@@ -359,21 +359,21 @@ macro_inline int vertex_cmp(const struct ls_vertex *node1,
 {
        return (node1->key - node2->key);
 }
-DECLARE_RBTREE_UNIQ(vertices, struct ls_vertex, entry, vertex_cmp)
+DECLARE_RBTREE_UNIQ(vertices, struct ls_vertex, entry, vertex_cmp);
 
 macro_inline int edge_cmp(const struct ls_edge *edge1,
                          const struct ls_edge *edge2)
 {
        return (edge1->key - edge2->key);
 }
-DECLARE_RBTREE_UNIQ(edges, struct ls_edge, entry, edge_cmp)
+DECLARE_RBTREE_UNIQ(edges, struct ls_edge, entry, edge_cmp);
 
 macro_inline int subnet_cmp(const struct ls_subnet *a,
                             const struct ls_subnet *b)
 {
        return prefix_cmp(&a->key, &b->key);
 }
-DECLARE_RBTREE_UNIQ(subnets, struct ls_subnet, entry, subnet_cmp)
+DECLARE_RBTREE_UNIQ(subnets, struct ls_subnet, entry, subnet_cmp);
 
 /* Link State TED Structure */
 struct ls_ted {
index cb3254cbe9305e9fd5824d346884487525c1d80c..c6cb36c058b3b052d46938303947069a4eb4cfb2 100644 (file)
@@ -43,7 +43,7 @@ static int qobj_cmp(const struct qobj_node *na, const struct qobj_node *nb)
 }
 
 DECLARE_HASH(qobj_nodes, struct qobj_node, nodehash,
-                       qobj_cmp, qobj_hash)
+                       qobj_cmp, qobj_hash);
 
 static pthread_rwlock_t nodes_lock;
 static struct qobj_nodes_head nodes = { };
index 6d66dbf80dc858d61527de021ac5771f1d1d8f9a..5012c98d7482eb04826138678caf4db42f6d360a 100644 (file)
@@ -83,7 +83,7 @@ struct qobj_nodetype {
        RESERVED_SPACE_STRUCT(qobj_nodetype_capnp, capnp, 256)
 };
 
-PREDECL_HASH(qobj_nodes)
+PREDECL_HASH(qobj_nodes);
 
 /* anchor to be embedded somewhere in the object's struct */
 struct qobj_node {
index 3153815680d02fe1b212814d26664e281200e386..dfd92c6189f58c47ba2ebc1a22ac7b775978642f 100644 (file)
@@ -41,7 +41,7 @@ static int route_table_hash_cmp(const struct route_node *a,
 }
 
 DECLARE_HASH(rn_hash_node, struct route_node, nodehash, route_table_hash_cmp,
-            prefix_hash_key)
+            prefix_hash_key);
 /*
  * route_table_init_with_delegate
  */
index ba922424feb45701d190705ab1aa9f50fbd6a235..7e383dce80874fa03384396d3726ce0a06ff07a7 100644 (file)
@@ -59,7 +59,7 @@ struct route_table_delegate_t_ {
        route_table_destroy_node_func_t destroy_node;
 };
 
-PREDECL_HASH(rn_hash_node)
+PREDECL_HASH(rn_hash_node);
 
 /* Routing table top structure. */
 struct route_table {
index e5826c5e5493de7f1f0c0dbaca2a5c0cc7433c4f..866090341e29071456631174e995424bbe5e82b4 100644 (file)
@@ -43,7 +43,7 @@ DEFINE_MTYPE_STATIC(LIB, THREAD_MASTER, "Thread master");
 DEFINE_MTYPE_STATIC(LIB, THREAD_POLL, "Thread Poll Info");
 DEFINE_MTYPE_STATIC(LIB, THREAD_STATS, "Thread stats");
 
-DECLARE_LIST(thread_list, struct thread, threaditem)
+DECLARE_LIST(thread_list, struct thread, threaditem);
 
 struct cancel_req {
        int flags;
@@ -68,7 +68,7 @@ static int thread_timer_cmp(const struct thread *a, const struct thread *b)
        return 0;
 }
 
-DECLARE_HEAP(thread_timer_list, struct thread, timeritem, thread_timer_cmp)
+DECLARE_HEAP(thread_timer_list, struct thread, timeritem, thread_timer_cmp);
 
 #if defined(__APPLE__)
 #include <mach/mach.h>
index cdef531ad461cbffa1ea6bf31e91cb298cda64f5..af6833113100b15442234585f886a9650eeba2e0 100644 (file)
@@ -41,8 +41,8 @@ struct rusage_t {
 
 #define GETRUSAGE(X) thread_getrusage(X)
 
-PREDECL_LIST(thread_list)
-PREDECL_HEAP(thread_timer_list)
+PREDECL_LIST(thread_list);
+PREDECL_HEAP(thread_timer_list);
 
 struct fd_handler {
        /* number of pfd that fit in the allocated space of pfds. This is a
index fca45e20d1c6a83f7cb21fa05785f061ba1c80d0..60e6d0901677f54a786ceec470759bdc0aa09b8c 100644 (file)
@@ -65,7 +65,8 @@ struct typed_rb_entry *typed_rb_next(const struct typed_rb_entry *rbe);
 
 #define _PREDECL_RBTREE(prefix)                                                \
 struct prefix ## _head { struct typed_rb_root rr; };                           \
-struct prefix ## _item { struct typed_rb_entry re; };
+struct prefix ## _item { struct typed_rb_entry re; };                          \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_RBTREE_UNIQ(var)          { }
 #define INIT_RBTREE_NONUNIQ(var)       { }
@@ -140,7 +141,7 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->rr.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define PREDECL_RBTREE_UNIQ(prefix)                                            \
        _PREDECL_RBTREE(prefix)
@@ -161,8 +162,8 @@ macro_inline const type *prefix ## _const_find(const struct prefix##_head *h,  \
 }                                                                              \
 TYPESAFE_FIND(prefix, type)                                                    \
                                                                                \
-_DECLARE_RBTREE(prefix, type, field, prefix ## __cmp, prefix ## __cmp)         \
-/* ... */
+_DECLARE_RBTREE(prefix, type, field, prefix ## __cmp, prefix ## __cmp);        \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define PREDECL_RBTREE_NONUNIQ(prefix)                                         \
        _PREDECL_RBTREE(prefix)
@@ -188,8 +189,8 @@ macro_inline int prefix ## __cmp_uq(const struct typed_rb_entry *a,            \
        return 0;                                                              \
 }                                                                              \
                                                                                \
-_DECLARE_RBTREE(prefix, type, field, prefix ## __cmp, prefix ## __cmp_uq)      \
-/* ... */
+_DECLARE_RBTREE(prefix, type, field, prefix ## __cmp, prefix ## __cmp_uq);     \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #ifdef __cplusplus
 }
index e134316dd9ddaff6002776866a419e465a1539bf..27e7be1286a2d4684ae34fd7d9b34c04e3bcc986 100644 (file)
@@ -105,15 +105,16 @@ static inline void typesafe_list_add(struct slist_head *head,
 
 /* use as:
  *
- * PREDECL_LIST(namelist)
+ * PREDECL_LIST(namelist);
  * struct name {
  *   struct namelist_item nlitem;
  * }
- * DECLARE_LIST(namelist, struct name, nlitem)
+ * DECLARE_LIST(namelist, struct name, nlitem);
  */
 #define PREDECL_LIST(prefix)                                                   \
 struct prefix ## _head { struct slist_head sh; };                              \
-struct prefix ## _item { struct slist_item si; };
+struct prefix ## _item { struct slist_item si; };                              \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_LIST(var) { .sh = { .last_next = &var.sh.first, }, }
 
@@ -191,7 +192,7 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->sh.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 /* don't use these structs directly */
 struct dlist_item {
@@ -218,7 +219,8 @@ static inline void typesafe_dlist_add(struct dlist_head *head,
  */
 #define PREDECL_DLIST(prefix)                                                  \
 struct prefix ## _head { struct dlist_head dh; };                              \
-struct prefix ## _item { struct dlist_item di; };
+struct prefix ## _item { struct dlist_item di; };                              \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_DLIST(var) { .dh = { \
        .hitem = { &var.dh.hitem, &var.dh.hitem }, }, }
@@ -295,7 +297,7 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->dh.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 /* note: heap currently caps out at 4G items */
 
@@ -319,7 +321,8 @@ struct heap_head {
 
 #define PREDECL_HEAP(prefix)                                                   \
 struct prefix ## _head { struct heap_head hh; };                               \
-struct prefix ## _item { struct heap_item hi; };
+struct prefix ## _item { struct heap_item hi; };                               \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_HEAP(var)         { }
 
@@ -402,7 +405,7 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->hh.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 extern void typesafe_heap_resize(struct heap_head *head, bool grow);
 extern void typesafe_heap_pushdown(struct heap_head *head, uint32_t index,
@@ -438,7 +441,8 @@ struct ssort_head {
  */
 #define _PREDECL_SORTLIST(prefix)                                              \
 struct prefix ## _head { struct ssort_head sh; };                              \
-struct prefix ## _item { struct ssort_item si; };
+struct prefix ## _item { struct ssort_item si; };                              \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_SORTLIST_UNIQ(var)                { }
 #define INIT_SORTLIST_NONUNIQ(var)     { }
@@ -537,10 +541,10 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->sh.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define DECLARE_SORTLIST_UNIQ(prefix, type, field, cmpfn)                      \
-       _DECLARE_SORTLIST(prefix, type, field, cmpfn, cmpfn)                   \
+       _DECLARE_SORTLIST(prefix, type, field, cmpfn, cmpfn);                  \
                                                                               \
 macro_inline const type *prefix ## _const_find(const struct prefix##_head *h,  \
                                               const type *item)               \
@@ -555,7 +559,7 @@ macro_inline const type *prefix ## _const_find(const struct prefix##_head *h,  \
        return container_of(sitem, type, field.si);                            \
 }                                                                              \
 TYPESAFE_FIND(prefix, type)                                                    \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define DECLARE_SORTLIST_NONUNIQ(prefix, type, field, cmpfn)                   \
 macro_inline int _ ## prefix ## _cmp(const type *a, const type *b)             \
@@ -569,8 +573,8 @@ macro_inline int _ ## prefix ## _cmp(const type *a, const type *b)             \
                return 1;                                                      \
        return 0;                                                              \
 }                                                                              \
-       _DECLARE_SORTLIST(prefix, type, field, cmpfn, _ ## prefix ## _cmp)     \
-/* ... */
+       _DECLARE_SORTLIST(prefix, type, field, cmpfn, _ ## prefix ## _cmp);    \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 
 /* hash, "sorted" by hash value
@@ -616,7 +620,8 @@ extern void typesafe_hash_shrink(struct thash_head *head);
  */
 #define PREDECL_HASH(prefix)                                                   \
 struct prefix ## _head { struct thash_head hh; };                              \
-struct prefix ## _item { struct thash_item hi; };
+struct prefix ## _item { struct thash_item hi; };                              \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_HASH(var) { }
 
@@ -734,7 +739,7 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->hh.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 /* skiplist, sorted.
  * can be used as priority queue with add / pop
@@ -769,7 +774,8 @@ struct sskip_head {
  */
 #define _PREDECL_SKIPLIST(prefix)                                              \
 struct prefix ## _head { struct sskip_head sh; };                              \
-struct prefix ## _item { struct sskip_item si; };
+struct prefix ## _item { struct sskip_item si; };                              \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define INIT_SKIPLIST_UNIQ(var)                { }
 #define INIT_SKIPLIST_NONUNIQ(var)     { }
@@ -840,7 +846,7 @@ macro_pure size_t prefix ## _count(const struct prefix##_head *h)              \
 {                                                                              \
        return h->sh.count;                                                    \
 }                                                                              \
-/* ... */
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define PREDECL_SKIPLIST_UNIQ(prefix)                                          \
        _PREDECL_SKIPLIST(prefix)
@@ -862,8 +868,8 @@ macro_inline const type *prefix ## _const_find(const struct prefix##_head *h,  \
 TYPESAFE_FIND(prefix, type)                                                    \
                                                                                \
 _DECLARE_SKIPLIST(prefix, type, field,                                         \
-               prefix ## __cmp, prefix ## __cmp)                              \
-/* ... */
+               prefix ## __cmp, prefix ## __cmp);                             \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 #define PREDECL_SKIPLIST_NONUNIQ(prefix)                                       \
        _PREDECL_SKIPLIST(prefix)
@@ -890,8 +896,8 @@ macro_inline int prefix ## __cmp_uq(const struct sskip_item *a,                \
 }                                                                              \
                                                                                \
 _DECLARE_SKIPLIST(prefix, type, field,                                         \
-               prefix ## __cmp, prefix ## __cmp_uq)                           \
-/* ... */
+               prefix ## __cmp, prefix ## __cmp_uq);                          \
+MACRO_REQUIRE_SEMICOLON() /* end */
 
 
 extern struct sskip_item *typesafe_skiplist_add(struct sskip_head *head,
index d95b801b2cff397255271c3ae68883be2b3b9bf4..140392bae658ac6e5ccc70226683bcc0392150ee 100644 (file)
@@ -203,7 +203,7 @@ extern size_t zlog_msg_ts(struct zlog_msg *msg, char *out, size_t outsz,
  * additional options.  It MUST be the first field in that larger struct.
  */
 
-PREDECL_ATOMLIST(zlog_targets)
+PREDECL_ATOMLIST(zlog_targets);
 struct zlog_target {
        struct zlog_targets_item head;
 
index 121e846843540ec01eae6d4ddbbc2de8f74e745e..d1931055a262e647047ee071ab29fa2c46edac09 100644 (file)
@@ -86,7 +86,7 @@ static int ospf6_vertex_cmp(const struct ospf6_vertex *va,
        return 0;
 }
 DECLARE_SKIPLIST_NONUNIQ(vertex_pqueue, struct ospf6_vertex, pqi,
-               ospf6_vertex_cmp)
+               ospf6_vertex_cmp);
 
 static int ospf6_vertex_id_cmp(void *a, void *b)
 {
index 36e2b2791225e9672ecc2256231a9e6f34cbda17..523b318d5bbeaf15797dcd412e0fde2ed18ba446 100644 (file)
@@ -35,7 +35,7 @@ extern unsigned char conf_debug_ospf6_spf;
 #define IS_OSPF6_DEBUG_SPF(level)                                              \
        (conf_debug_ospf6_spf & OSPF6_DEBUG_SPF_##level)
 
-PREDECL_SKIPLIST_NONUNIQ(vertex_pqueue)
+PREDECL_SKIPLIST_NONUNIQ(vertex_pqueue);
 /* Transit Vertex */
 struct ospf6_vertex {
        /* type of this vertex */
index 6cd6a47098fe82f85a5a2ef75138387f67d009fd..1e0814764bb5bc3ee583d25bf8faeda96a02255e 100644 (file)
@@ -89,7 +89,7 @@ static int vertex_cmp(const struct vertex *v1, const struct vertex *v2)
        }
        return 0;
 }
-DECLARE_SKIPLIST_NONUNIQ(vertex_pqueue, struct vertex, pqi, vertex_cmp)
+DECLARE_SKIPLIST_NONUNIQ(vertex_pqueue, struct vertex, pqi, vertex_cmp);
 
 static void lsdb_clean_stat(struct ospf_lsdb *lsdb)
 {
index 66555be4b705ffd22916254aba104ae0fe962de0..835caab288ea945f90cb377c7f60a48ae04db68b 100644 (file)
@@ -33,7 +33,7 @@
 
 /* The "root" is the node running the SPF calculation */
 
-PREDECL_SKIPLIST_NONUNIQ(vertex_pqueue)
+PREDECL_SKIPLIST_NONUNIQ(vertex_pqueue);
 /* A router or network in an area */
 struct vertex {
        struct vertex_pqueue_item pqi;
index 4a0186bfb917ab4bbb76d9b602bf583a3d85faf2..59b3b624e3903f016130172c440aec9b2c394a62 100644 (file)
@@ -37,9 +37,9 @@
 
 
 DECLARE_RBTREE_UNIQ(p_spaces, struct p_space, p_spaces_item,
-                   p_spaces_compare_func)
+                   p_spaces_compare_func);
 DECLARE_RBTREE_UNIQ(q_spaces, struct q_space, q_spaces_item,
-                   q_spaces_compare_func)
+                   q_spaces_compare_func);
 
 static void
 ospf_ti_lfa_generate_p_space(struct ospf_area *area, struct vertex *child,
index 4005f2f21b57c1a9740e880ea2babe6891637873..1a1861fc58d52f5995ed1ebe8d91d858b1979a0c 100644 (file)
@@ -111,7 +111,7 @@ int q_spaces_compare_func(const struct q_space *a, const struct q_space *b)
 }
 
 DECLARE_RBTREE_UNIQ(p_spaces, struct p_space, p_spaces_item,
-                   p_spaces_compare_func)
+                   p_spaces_compare_func);
 
 void ospf_process_refresh_data(struct ospf *ospf, bool reset)
 {
index 0ac13f92fd585f691e0410eaf757f6b16dca45fd..5d64ee9ba21fa1da21a102297f6e9fe840a4f5c1 100644 (file)
@@ -424,7 +424,7 @@ struct protected_resource {
        struct in_addr router_id;
 };
 
-PREDECL_RBTREE_UNIQ(q_spaces)
+PREDECL_RBTREE_UNIQ(q_spaces);
 struct q_space {
        struct vertex *root;
        struct list *vertex_list;
@@ -436,7 +436,7 @@ struct q_space {
        struct q_spaces_item q_spaces_item;
 };
 
-PREDECL_RBTREE_UNIQ(p_spaces)
+PREDECL_RBTREE_UNIQ(p_spaces);
 struct p_space {
        struct vertex *root;
        struct protected_resource *protected_resource;
index 9de3ba7811e1810a05a26336ce8e36a3506285f1..d951c045408c6a13914d2e2c11ac7af97ab0ee98 100644 (file)
@@ -147,10 +147,10 @@ static uint32_t req_map_hash(const struct req_map_data *e);
 
 /* Data Structure Declarations */
 DECLARE_HASH(plspid_map, struct plspid_map_data, mi, plspid_map_cmp,
-            plspid_map_hash)
+            plspid_map_hash);
 DECLARE_HASH(nbkey_map, struct nbkey_map_data, mi, nbkey_map_cmp,
-            nbkey_map_hash)
-DECLARE_HASH(req_map, struct req_map_data, mi, req_map_cmp, req_map_hash)
+            nbkey_map_hash);
+DECLARE_HASH(req_map, struct req_map_data, mi, req_map_cmp, req_map_hash);
 
 static inline int req_entry_compare(const struct req_entry *a,
                                    const struct req_entry *b)
index c07a6ae541411b47a6f0e3b0dd9dc0ac56ace144..ceac6f32781013c169103a3bcb3cc63bf0678b96 100644 (file)
@@ -30,9 +30,9 @@ enum pcc_status {
        PCEP_PCC_OPERATING
 };
 
-PREDECL_HASH(plspid_map)
-PREDECL_HASH(nbkey_map)
-PREDECL_HASH(req_map)
+PREDECL_HASH(plspid_map);
+PREDECL_HASH(nbkey_map);
+PREDECL_HASH(req_map);
 
 struct plspid_map_data {
        struct plspid_map_item mi;
index 8a808afa73a23fe787310444972d09d7c578cd96..b0aa2b17c584daf28390622180f58a2fa0a779f7 100644 (file)
@@ -90,7 +90,7 @@ struct channel_counts {
   installed: indicate if this entry is installed in the kernel.
 
 */
-PREDECL_RBTREE_UNIQ(rb_pim_oil)
+PREDECL_RBTREE_UNIQ(rb_pim_oil);
 
 struct channel_oil {
        struct pim_instance *pim;
@@ -112,7 +112,7 @@ struct channel_oil {
 extern int pim_channel_oil_compare(const struct channel_oil *c1,
                                   const struct channel_oil *c2);
 DECLARE_RBTREE_UNIQ(rb_pim_oil, struct channel_oil, oil_rb,
-                    pim_channel_oil_compare)
+                    pim_channel_oil_compare);
 
 
 extern struct list *pim_channel_oil_list;
index 8030835fb247312ccc709728d821d8c5d10aba8d..adea3cd9efa25fd76b139b87f66a4f646b3e0ebe 100644 (file)
@@ -373,7 +373,7 @@ void join_timer_start(struct pim_upstream *up);
 int pim_upstream_compare(const struct pim_upstream *up1,
                         const struct pim_upstream *up2);
 DECLARE_RBTREE_UNIQ(rb_pim_upstream, struct pim_upstream, upstream_rb,
-                   pim_upstream_compare)
+                   pim_upstream_compare);
 
 void pim_upstream_register_reevaluate(struct pim_instance *pim);
 
index 391ccd9268af72002311a4cfca762df296a3cdc9..fde0d6af520f63a8a1503a67e6e5c9388927be97 100644 (file)
 #include "lib/zassert.h"
 #include "lib/zclient.h"
 
-PREDECL_RBTREE_UNIQ(footree)
+PREDECL_RBTREE_UNIQ(footree);
 struct foo {
        int dummy;
        struct footree_item item;
@@ -116,7 +116,7 @@ static int foocmp(const struct foo *a, const struct foo *b)
 {
        return memcmp(&a->dummy, &b->dummy, sizeof(a->dummy));
 }
-DECLARE_RBTREE_UNIQ(footree, struct foo, item, foocmp)
+DECLARE_RBTREE_UNIQ(footree, struct foo, item, foocmp);
 
 int main(int argc, char **argv)
 {
index 40837b4722835e8c9abd123fa23ddac9871a6a45..83dd9f2c590457023b43b84c8adc398bbe4dc868 100644 (file)
 
 static struct seqlock sqlo;
 
-PREDECL_ATOMLIST(alist)
-PREDECL_ATOMSORT_UNIQ(asort)
+PREDECL_ATOMLIST(alist);
+PREDECL_ATOMSORT_UNIQ(asort);
 struct item {
        uint64_t val1;
        struct alist_item chain;
        struct asort_item sortc;
        uint64_t val2;
 };
-DECLARE_ATOMLIST(alist, struct item, chain)
+DECLARE_ATOMLIST(alist, struct item, chain);
 
 static int icmp(const struct item *a, const struct item *b);
-DECLARE_ATOMSORT_UNIQ(asort, struct item, sortc, icmp)
+DECLARE_ATOMSORT_UNIQ(asort, struct item, sortc, icmp);
 
 static int icmp(const struct item *a, const struct item *b)
 {
index f86cadd39858bbea772f055488bc961b04348eae..32331c14a03788006a7e6348114a8c998717e773 100644 (file)
@@ -47,7 +47,7 @@
 #define REALTYPE TYPE
 #endif
 
-PREDECL(REALTYPE, list)
+PREDECL(REALTYPE, list);
 struct item {
        uint64_t val;
        struct list_item itm;
@@ -59,7 +59,7 @@ static int list_cmp(const struct item *a, const struct item *b);
 
 #if IS_HASH(REALTYPE)
 static uint32_t list_hash(const struct item *a);
-DECLARE(REALTYPE, list, struct item, itm, list_cmp, list_hash)
+DECLARE(REALTYPE, list, struct item, itm, list_cmp, list_hash);
 
 static uint32_t list_hash(const struct item *a)
 {
@@ -72,7 +72,7 @@ static uint32_t list_hash(const struct item *a)
 }
 
 #else
-DECLARE(REALTYPE, list, struct item, itm, list_cmp)
+DECLARE(REALTYPE, list, struct item, itm, list_cmp);
 #endif
 
 static int list_cmp(const struct item *a, const struct item *b)
@@ -85,7 +85,7 @@ static int list_cmp(const struct item *a, const struct item *b)
 }
 
 #else /* !IS_SORTED */
-DECLARE(REALTYPE, list, struct item, itm)
+DECLARE(REALTYPE, list, struct item, itm);
 #endif
 
 #define NITEM 10000
index a85f7e14eceb5a0c210815c3f018920132c83bdd..7808c3d47d3ab3798d81c9f29082e0d665f6539c 100644 (file)
@@ -23,9 +23,9 @@
 #include "common.h"
 
 DECLARE_RBTREE_UNIQ(p_spaces, struct p_space, p_spaces_item,
-                   p_spaces_compare_func)
+                   p_spaces_compare_func);
 DECLARE_RBTREE_UNIQ(q_spaces, struct q_space, q_spaces_item,
-                   q_spaces_compare_func)
+                   q_spaces_compare_func);
 
 static struct ospf *test_init(struct ospf_test_node *root)
 {
index 0c98ad533507e24c38ae9f249a3775a0f8f2e7c7..498d3e5f67328be753cf874f6abb2e3952b9f438 100644 (file)
@@ -91,9 +91,9 @@ static uint32_t config_hash(const struct config *c)
        return string_hash_make(c->name);
 }
 
-DECLARE_LIST(config_master, struct config, rbt_item)
+DECLARE_LIST(config_master, struct config, rbt_item);
 DECLARE_HASH(config_master_hash, struct config, hash_item, config_cmp,
-            config_hash)
+            config_hash);
 
 /*
  * The config_master_head is a list for order of receipt
index 68b62f501b5f5831e25f9dbf8c627fde87c910aa..564e27497d812d05d34be55075a1a2f8a53cb1cf 100644 (file)
@@ -43,7 +43,7 @@ extern "C" {
 
 enum rnh_type { RNH_NEXTHOP_TYPE, RNH_IMPORT_CHECK_TYPE };
 
-PREDECL_LIST(rnh_list)
+PREDECL_LIST(rnh_list);
 
 /* Nexthop structure. */
 struct rnh {
@@ -82,7 +82,7 @@ struct rnh {
 #define DISTANCE_INFINITY  255
 #define ZEBRA_KERNEL_TABLE_MAX 252 /* support for no more than this rt tables */
 
-PREDECL_LIST(re_list)
+PREDECL_LIST(re_list);
 
 struct opaque {
        uint16_t length;
index 910d1923175fad9105565ac79fc2499f101ce509..ed6376b01f14072211b41a028e83213e04ad999f 100644 (file)
@@ -238,7 +238,7 @@ zvrf_other_table_compare_func(const struct other_route_table *a,
 }
 
 DECLARE_RBTREE_UNIQ(otable, struct other_route_table, next,
-                   zvrf_other_table_compare_func)
+                   zvrf_other_table_compare_func);
 
 extern struct route_table *
 zebra_vrf_lookup_table_with_table_id(afi_t afi, safi_t safi, vrf_id_t vrf_id,