summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorJ. Bruce Fields <bfields@redhat.com>2012-08-14 23:48:39 +0200
committerJ. Bruce Fields <bfields@redhat.com>2012-08-21 23:07:50 +0200
commita10fded18eb275e7e97e57e7542b16c665fe61ec (patch)
tree4171899172269fbc100107a17912429d0fcdad5b /fs
parentnfsd: remove redundant "port" argument (diff)
downloadlinux-a10fded18eb275e7e97e57e7542b16c665fe61ec.tar.xz
linux-a10fded18eb275e7e97e57e7542b16c665fe61ec.zip
nfsd: allow configuring nfsd to listen on 5-digit ports
Note a 16-bit value can require up to 5 digits. Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfsd/nfsctl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c
index 89be13c9e769..e41a08ffbe0a 100644
--- a/fs/nfsd/nfsctl.c
+++ b/fs/nfsd/nfsctl.c
@@ -712,7 +712,7 @@ static ssize_t __write_ports_addxprt(char *buf)
int port, err;
struct net *net = &init_net;
- if (sscanf(buf, "%15s %4u", transport, &port) != 2)
+ if (sscanf(buf, "%15s %5u", transport, &port) != 2)
return -EINVAL;
if (port < 1 || port > USHRT_MAX)