FBSD: Remove unused 'wantparent' logic 43/14143/2
authorAndrew Deason <adeason@dson.org>
Mon, 13 Apr 2020 03:40:14 +0000 (22:40 -0500)
committerBenjamin Kaduk <kaduk@mit.edu>
Fri, 17 Apr 2020 23:55:18 +0000 (19:55 -0400)
commit7df5c003ed6eb17a693d67ffdfc0556f0c569cc1
treeec0dee344adaa9aef1a1a9e6bf41765d2f577965
parent7116de596a8f1d0be3da6eebe92d486f57aefd02
FBSD: Remove unused 'wantparent' logic

In afs_vop_lookup, the 'wantparent' variable doesn't actually change
any logic in the function. In the if() clause that it's used, the
value of 'wantparent' is only ever used if cnp->cn_nameiop is RENAME
and ISLASTCN is set. But if both of those are true, then the second
half of the if() conditional will always be true, so the value of
'wantparent' doesn't matter.

So to remove this confusing unused logic, remove the 'wantparent'
local var, and all its associated logic.

Issue spotted by kaduk@mit.edu.

Change-Id: Ia63b88d67d21cc2b81a0c25aa31ea60ab202b0a7
Reviewed-on: https://gerrit.openafs.org/14143
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
src/afs/FBSD/osi_vnodeops.c