diff options
| author | Quentin Young <qlyoung@cumulusnetworks.com> | 2018-03-27 15:13:34 -0400 |
|---|---|---|
| committer | Quentin Young <qlyoung@cumulusnetworks.com> | 2018-03-27 15:13:34 -0400 |
| commit | d7c0a89a3a5697783a6dd89333ab660074790890 (patch) | |
| tree | eefa73e502f919b524b8a345437260d4acc23083 /ospf6d/ospf6_lsdb.c | |
| parent | 28ac5a038101c66e4275a9b1ef6fb37b4f74fb6a (diff) | |
*: use C99 standard fixed-width integer types
The following types are nonstandard:
- u_char
- u_short
- u_int
- u_long
- u_int8_t
- u_int16_t
- u_int32_t
Replace them with the C99 standard types:
- uint8_t
- unsigned short
- unsigned int
- unsigned long
- uint8_t
- uint16_t
- uint32_t
Signed-off-by: Quentin Young <qlyoung@cumulusnetworks.com>
Diffstat (limited to 'ospf6d/ospf6_lsdb.c')
| -rw-r--r-- | ospf6d/ospf6_lsdb.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/ospf6d/ospf6_lsdb.c b/ospf6d/ospf6_lsdb.c index f17b558e8b..5e02c0c917 100644 --- a/ospf6d/ospf6_lsdb.c +++ b/ospf6d/ospf6_lsdb.c @@ -173,8 +173,8 @@ void ospf6_lsdb_remove(struct ospf6_lsa *lsa, struct ospf6_lsdb *lsdb) ospf6_lsdb_count_assert(lsdb); } -struct ospf6_lsa *ospf6_lsdb_lookup(u_int16_t type, u_int32_t id, - u_int32_t adv_router, +struct ospf6_lsa *ospf6_lsdb_lookup(uint16_t type, uint32_t id, + uint32_t adv_router, struct ospf6_lsdb *lsdb) { struct route_node *node; @@ -196,8 +196,8 @@ struct ospf6_lsa *ospf6_lsdb_lookup(u_int16_t type, u_int32_t id, return (struct ospf6_lsa *)node->info; } -struct ospf6_lsa *ospf6_lsdb_lookup_next(u_int16_t type, u_int32_t id, - u_int32_t adv_router, +struct ospf6_lsa *ospf6_lsdb_lookup_next(uint16_t type, uint32_t id, + uint32_t adv_router, struct ospf6_lsdb *lsdb) { struct route_node *node; @@ -355,7 +355,7 @@ int ospf6_lsdb_maxage_remover(struct ospf6_lsdb *lsdb) } void ospf6_lsdb_show(struct vty *vty, enum ospf_lsdb_show_level level, - u_int16_t *type, u_int32_t *id, u_int32_t *adv_router, + uint16_t *type, uint32_t *id, uint32_t *adv_router, struct ospf6_lsdb *lsdb) { struct ospf6_lsa *lsa; @@ -403,11 +403,11 @@ void ospf6_lsdb_show(struct vty *vty, enum ospf_lsdb_show_level level, } } -u_int32_t ospf6_new_ls_id(u_int16_t type, u_int32_t adv_router, - struct ospf6_lsdb *lsdb) +uint32_t ospf6_new_ls_id(uint16_t type, uint32_t adv_router, + struct ospf6_lsdb *lsdb) { struct ospf6_lsa *lsa; - u_int32_t id = 1, tmp_id; + uint32_t id = 1, tmp_id; /* This routine is curently invoked only for Inter-Prefix LSAs for * non-summarized routes (no area/range). @@ -424,13 +424,13 @@ u_int32_t ospf6_new_ls_id(u_int16_t type, u_int32_t adv_router, id++; } - return ((u_int32_t)htonl(id)); + return ((uint32_t)htonl(id)); } /* Decide new LS sequence number to originate. note return value is network byte order */ -u_int32_t ospf6_new_ls_seqnum(u_int16_t type, u_int32_t id, - u_int32_t adv_router, struct ospf6_lsdb *lsdb) +uint32_t ospf6_new_ls_seqnum(uint16_t type, uint32_t id, uint32_t adv_router, + struct ospf6_lsdb *lsdb) { struct ospf6_lsa *lsa; signed long seqnum = 0; @@ -442,5 +442,5 @@ u_int32_t ospf6_new_ls_seqnum(u_int16_t type, u_int32_t id, else seqnum = (signed long)ntohl(lsa->header->seqnum) + 1; - return ((u_int32_t)htonl(seqnum)); + return ((uint32_t)htonl(seqnum)); } |
