diff mbox series

[2/2] arpd: drop useless initializers

Message ID 20240919132454.7394-2-dario.binacchi@amarulasolutions.com (mailing list archive)
State New
Headers show
Series [1/2] arpd: use designated initializers for msghdr structure | expand

Checks

Context Check Description
netdev/tree_selection success Not a local patch

Commit Message

Dario Binacchi Sept. 19, 2024, 1:24 p.m. UTC
It is useless to initialize the fields of a structure to their default
values. This patch keeps the initialization only for those fields that
are not set to their default values.

Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com>
---
 misc/arpd.c | 2 --
 1 file changed, 2 deletions(-)
diff mbox series

Patch

diff --git a/misc/arpd.c b/misc/arpd.c
index b4935c23eebb..a2ae76a41f8d 100644
--- a/misc/arpd.c
+++ b/misc/arpd.c
@@ -439,8 +439,6 @@  static void get_kern_msg(void)
 	struct msghdr msg = {
 		.msg_name = &nladdr, .msg_namelen = sizeof(nladdr),
 		.msg_iov = &iov, .msg_iovlen = 1,
-		.msg_control = (void *)NULL, .msg_controllen = 0,
-		.msg_flags = 0
 	};
 
 	iov.iov_base = buf;