diff options
author | rmacklem <rmacklem@FreeBSD.org> | 2017-07-07 21:33:06 +0000 |
---|---|---|
committer | rmacklem <rmacklem@FreeBSD.org> | 2017-07-07 21:33:06 +0000 |
commit | 5bfd029b629cd6065fdc8130ac0ccf1c57ea1852 (patch) | |
tree | 588efb373d525c28226c9b8e0311da81bb951dd1 /lib | |
parent | 44ed9064a08ad37fb8aca5c20740f1dba5a028aa (diff) | |
download | FreeBSD-src-5bfd029b629cd6065fdc8130ac0ccf1c57ea1852.zip FreeBSD-src-5bfd029b629cd6065fdc8130ac0ccf1c57ea1852.tar.gz |
MFC: r320208
Ensure that the credentials field of the NFSv4 client open structure is
initialized.
bdrewery@ has reported panics "newnfs_copycred: negative nfsc_ngroups".
The only way I can see that this occurs is that the credentials field of
the open structure gets used before being filled in.
I am not sure quite how this happens, but for the file create case, the
code is serialized via the vnode lock on the directory. If, somehow, a
link to the same file gets created just after file creation, this might
occur.
This patch ensures that the credentials field is initialized to a reasonable
set of credentials before the structure is linked into any list, so I
this should ensure it is initialized before use.
I am committing the patch now, since bdrewery@ notes that the panics
are intermittent and it may be months before he knows if the patch fixes
his problem.
Diffstat (limited to 'lib')
0 files changed, 0 insertions, 0 deletions