summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorZhou jie <zhoujie@nfschina.com>2022-08-23 11:45:52 +0800
committerWei Liu <wei.liu@kernel.org>2022-09-05 16:55:20 +0000
commit2258954234db7530e9d86bb32cd6ad54485ff926 (patch)
tree7d053abfc7f987729b03bdc7bf9bc8be41adea92 /tools
parent676576d164b34a98589a9efee85f57240c07fef3 (diff)
downloadlwn-2258954234db7530e9d86bb32cd6ad54485ff926.tar.gz
lwn-2258954234db7530e9d86bb32cd6ad54485ff926.zip
tools: hv: kvp: remove unnecessary (void*) conversions
Remove unnecessary void* type casting. Signed-off-by: Zhou jie <zhoujie@nfschina.com> Reviewed-by: Michael Kelley <mikelley@microsoft.com> Link: https://lore.kernel.org/r/20220823034552.8596-1-zhoujie@nfschina.com Signed-off-by: Wei Liu <wei.liu@kernel.org>
Diffstat (limited to 'tools')
-rw-r--r--tools/hv/hv_kvp_daemon.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/hv/hv_kvp_daemon.c b/tools/hv/hv_kvp_daemon.c
index c97c12e95ecb..27f5e7dfc2f7 100644
--- a/tools/hv/hv_kvp_daemon.c
+++ b/tools/hv/hv_kvp_daemon.c
@@ -772,11 +772,11 @@ static int kvp_process_ip_address(void *addrp,
const char *str;
if (family == AF_INET) {
- addr = (struct sockaddr_in *)addrp;
+ addr = addrp;
str = inet_ntop(family, &addr->sin_addr, tmp, 50);
addr_length = INET_ADDRSTRLEN;
} else {
- addr6 = (struct sockaddr_in6 *)addrp;
+ addr6 = addrp;
str = inet_ntop(family, &addr6->sin6_addr.s6_addr, tmp, 50);
addr_length = INET6_ADDRSTRLEN;
}