When building with clang, via:
make LLVM=1 -C tools/testing/selftest
...clang warns about using "int *" interchangeably with "socklen_t *".
clang is correct, so fix this by declaring len as a socklen_t, instead of as an int.
Signed-off-by: John Hubbard jhubbard@nvidia.com --- tools/testing/selftests/netfilter/sctp_collision.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/tools/testing/selftests/netfilter/sctp_collision.c b/tools/testing/selftests/netfilter/sctp_collision.c index 21bb1cfd8a85..91df996367e9 100644 --- a/tools/testing/selftests/netfilter/sctp_collision.c +++ b/tools/testing/selftests/netfilter/sctp_collision.c @@ -9,7 +9,8 @@ int main(int argc, char *argv[]) { struct sockaddr_in saddr = {}, daddr = {}; - int sd, ret, len = sizeof(daddr); + int sd, ret; + socklen_t len = sizeof(daddr); struct timeval tv = {25, 0}; char buf[] = "hello";
base-commit: f462ae0edd3703edd6f22fe41d336369c38b884b prerequisite-patch-id: b901ece2a5b78503e2fb5480f20e304d36a0ea27