Skip to content

Commit da4f777

Browse files
committed
NFSD: Remove a never-true comparison
fh_size is an unsigned int, thus it can never be less than 0. Fixes: d8b2607 ("NFSD: simplify struct nfsfh") Reviewed-by: Jeff Layton <[email protected]> Signed-off-by: Chuck Lever <[email protected]>
1 parent d08bf5e commit da4f777

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fs/nfsd/nfsfh.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -766,7 +766,7 @@ char * SVCFH_fmt(struct svc_fh *fhp)
766766
struct knfsd_fh *fh = &fhp->fh_handle;
767767
static char buf[2+1+1+64*3+1];
768768

769-
if (fh->fh_size < 0 || fh->fh_size> 64)
769+
if (fh->fh_size > 64)
770770
return "bad-fh";
771771
sprintf(buf, "%d: %*ph", fh->fh_size, fh->fh_size, fh->fh_raw);
772772
return buf;

0 commit comments

Comments
 (0)