Commit 40927f3
nfsd: fix nfsd4_deleg_getattr_conflict in presence of third party lease
It is not safe to dereference fl->c.flc_owner without first confirming
fl->fl_lmops is the expected manager. nfsd4_deleg_getattr_conflict()
tests fl_lmops but largely ignores the result and assumes that flc_owner
is an nfs4_delegation anyway. This is wrong.
With this patch we restore the "!= &nfsd_lease_mng_ops" case to behave
as it did before the change mentioned below. This is the same as the
current code, but without any reference to a possible delegation.
Fixes: c596772 ("NFSD: handle GETATTR conflict with write delegation")
Signed-off-by: NeilBrown <[email protected]>
Reviewed-by: Jeff Layton <[email protected]>
Signed-off-by: Chuck Lever <[email protected]>1 parent 7e8ae84 commit 40927f3
1 file changed
+9
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8859 | 8859 | | |
8860 | 8860 | | |
8861 | 8861 | | |
8862 | | - | |
| 8862 | + | |
| 8863 | + | |
| 8864 | + | |
| 8865 | + | |
| 8866 | + | |
| 8867 | + | |
| 8868 | + | |
| 8869 | + | |
| 8870 | + | |
8863 | 8871 | | |
8864 | 8872 | | |
8865 | 8873 | | |
| |||
8868 | 8876 | | |
8869 | 8877 | | |
8870 | 8878 | | |
8871 | | - | |
8872 | 8879 | | |
8873 | 8880 | | |
8874 | 8881 | | |
| |||
0 commit comments