Home
last modified time | relevance | path

Searched hist:"818 f2f57" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/fs/nfsd/
H A Dnfsctl.c818f2f57 Thu Nov 27 09:58:54 CST 2014 Dan Carpenter <dan.carpenter@oracle.com> nfsd: minor off by one checks in __write_versions()

My static checker complains that if "len == remaining" then it means we
have truncated the last character off the version string.

The intent of the code is that we print as many versions as we can
without truncating a version. Then we put a newline at the end. If the
newline can't fit we return -EINVAL.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Jeff Layton <jlayton@primarydata.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
818f2f57 Thu Nov 27 09:58:54 CST 2014 Dan Carpenter <dan.carpenter@oracle.com> nfsd: minor off by one checks in __write_versions()

My static checker complains that if "len == remaining" then it means we
have truncated the last character off the version string.

The intent of the code is that we print as many versions as we can
without truncating a version. Then we put a newline at the end. If the
newline can't fit we return -EINVAL.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Jeff Layton <jlayton@primarydata.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>