]> git.baikalelectronics.ru Git - kernel.git/commit
selftests/net: in rxtimestamp getopt_long needs terminating null entry
authortannerlove <tannerlove@google.com>
Tue, 9 Jun 2020 21:21:32 +0000 (17:21 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 9 Jun 2020 21:31:33 +0000 (14:31 -0700)
commit741db7dc452fd8488691682b184346d31f8af486
treea887b5bc589ed6af7a7c0d9331b28092cb37a0a0
parent9ea46e2cf56033df1d26d92cb9342e4418b6921e
selftests/net: in rxtimestamp getopt_long needs terminating null entry

getopt_long requires the last element to be filled with zeros.
Otherwise, passing an unrecognized option can cause a segfault.

Fixes: 7ccbc02b1076 ("selftests/net: Add a test to validate behavior of rx timestamps")
Signed-off-by: Tanner Love <tannerlove@google.com>
Acked-by: Willem de Bruijn <willemb@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
tools/testing/selftests/net/rxtimestamp.c