summaryrefslogtreecommitdiffstats
path: root/ripd
diff options
context:
space:
mode:
authorDonatas Abraitis <donatas.abraitis@gmail.com>2020-03-08 20:43:26 +0100
committerDonatas Abraitis <donatas.abraitis@gmail.com>2020-03-08 20:44:53 +0100
commit0d6f7fd6fd9dcaa62fb77a10d3a1ad8d0d74f980 (patch)
treedb39fd913f349a353a62ead250210aab49a8cc09 /ripd
parentMerge pull request #5924 from donaldsharp/more_func (diff)
downloadfrr-0d6f7fd6fd9dcaa62fb77a10d3a1ad8d0d74f980.tar.xz
frr-0d6f7fd6fd9dcaa62fb77a10d3a1ad8d0d74f980.zip
*: Replace `sizeof something` to sizeof(something)
Satisfy checkpatch.pl requirements (check for sizeof without parenthesis) Signed-off-by: Donatas Abraitis <donatas.abraitis@gmail.com>
Diffstat (limited to 'ripd')
-rw-r--r--ripd/rip_interface.c2
-rw-r--r--ripd/rip_snmp.c2
-rw-r--r--ripd/ripd.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/ripd/rip_interface.c b/ripd/rip_interface.c
index 2ed8d5394..c05d776eb 100644
--- a/ripd/rip_interface.c
+++ b/ripd/rip_interface.c
@@ -216,7 +216,7 @@ rip_request_neighbor (struct in_addr addr)
{
struct sockaddr_in to;
- memset (&to, 0, sizeof (struct sockaddr_in));
+ memset (&to, 0, sizeof(struct sockaddr_in));
to.sin_port = htons (RIP_PORT_DEFAULT);
to.sin_addr = addr;
diff --git a/ripd/rip_snmp.c b/ripd/rip_snmp.c
index 39e07f3c2..be222c7a5 100644
--- a/ripd/rip_snmp.c
+++ b/ripd/rip_snmp.c
@@ -553,7 +553,7 @@ static uint8_t *rip2PeerTable(struct variable *v, oid name[], size_t *length,
* - don't support this variable, at all
* Currently, we do the latter...
*/
- *val_len = sizeof (time_t);
+ *val_len = sizeof(time_t);
uptime = peer->uptime; /* now - snmp_agent_startup - peer->uptime */
return (uint8_t *) &uptime;
#else
diff --git a/ripd/ripd.c b/ripd/ripd.c
index 5009b788f..f092da847 100644
--- a/ripd/ripd.c
+++ b/ripd/ripd.c
@@ -104,7 +104,7 @@ static int sockopt_broadcast(int sock)
int on = 1;
ret = setsockopt(sock, SOL_SOCKET, SO_BROADCAST, (char *)&on,
- sizeof on);
+ sizeof(on));
if (ret < 0) {
zlog_warn("can't set sockopt SO_BROADCAST to socket %d", sock);
return -1;