8dc7c3115b
posix_test_lock() returns a pointer to a struct file_lock which is unprotected and can be removed while in use by the caller. Move the conflicting lock from the return to a parameter, and copy the conflicting lock. In most cases the caller ends up putting the copy of the conflicting lock on the stack. On i386, sizeof(struct file_lock) appears to be about 100 bytes. We're assuming that's reasonable. Signed-off-by: Andy Adamson <andros@citi.umich.edu> Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com> |
||
---|---|---|
.. | ||
callback.c | ||
callback.h | ||
callback_proc.c | ||
callback_xdr.c | ||
delegation.c | ||
delegation.h | ||
dir.c | ||
direct.c | ||
file.c | ||
idmap.c | ||
inode.c | ||
iostat.h | ||
Makefile | ||
mount_clnt.c | ||
nfs2xdr.c | ||
nfs3acl.c | ||
nfs3proc.c | ||
nfs3xdr.c | ||
nfs4_fs.h | ||
nfs4proc.c | ||
nfs4renewd.c | ||
nfs4state.c | ||
nfs4xdr.c | ||
nfsroot.c | ||
pagelist.c | ||
proc.c | ||
read.c | ||
symlink.c | ||
sysctl.c | ||
unlink.c | ||
write.c |