提交 12127498 编写于 作者: A Andrew Morton 提交者: Linus Torvalds

nfsd warning fix

gcc-4.3:

fs/nfsd/nfsctl.c: In function 'write_getfs':
fs/nfsd/nfsctl.c:248: warning: cast from pointer to integer of different size

Cc: Neil Brown <neilb@suse.de>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 019ab801
......@@ -245,7 +245,7 @@ static ssize_t write_getfs(struct file *file, char *buf, size_t size)
}
exp_readunlock();
if (err == 0)
err = res->fh_size + (int)&((struct knfsd_fh*)0)->fh_base;
err = res->fh_size + offsetof(struct knfsd_fh, fh_base);
out:
return err;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册