summaryrefslogtreecommitdiffstats
path: root/net/9p/trans_fd.c
diff options
context:
space:
mode:
authorAlexander Kapshuk <alexander.kapshuk@gmail.com>2020-06-18 20:34:17 +0200
committerDominique Martinet <asmadeus@codewreck.org>2020-07-19 14:58:47 +0200
commit6db6ea79c525f3d753e270c84d72b3a900ad33fb (patch)
treed0ad9dff0933946824e2cfe4cdd42687a24b6a33 /net/9p/trans_fd.c
parent9p: Fix memory leak in v9fs_mount (diff)
downloadlinux-6db6ea79c525f3d753e270c84d72b3a900ad33fb.tar.xz
linux-6db6ea79c525f3d753e270c84d72b3a900ad33fb.zip
net/9p: Fix sparse endian warning in trans_fd.c
Address sparse endian warning: net/9p/trans_fd.c:932:28: warning: incorrect type in assignment (different base types) net/9p/trans_fd.c:932:28: expected restricted __be32 [addressable] [assigned] [usertype] s_addr net/9p/trans_fd.c:932:28: got unsigned long Link: http://lkml.kernel.org/r/20200618183417.5423-1-alexander.kapshuk@gmail.com Signed-off-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
Diffstat (limited to 'net/9p/trans_fd.c')
-rw-r--r--net/9p/trans_fd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/9p/trans_fd.c b/net/9p/trans_fd.c
index 12ecacf0c55f..c0762a302162 100644
--- a/net/9p/trans_fd.c
+++ b/net/9p/trans_fd.c
@@ -950,7 +950,7 @@ static int p9_bind_privport(struct socket *sock)
memset(&cl, 0, sizeof(cl));
cl.sin_family = AF_INET;
- cl.sin_addr.s_addr = INADDR_ANY;
+ cl.sin_addr.s_addr = htonl(INADDR_ANY);
for (port = p9_ipport_resv_max; port >= p9_ipport_resv_min; port--) {
cl.sin_port = htons((ushort)port);
err = kernel_bind(sock, (struct sockaddr *)&cl, sizeof(cl));