vol: prevent salvage segfault for orphaned vnode with out-of-range parent
While salvaging a RW volume, salvager may segfault if it encounters an
orphaned directory with a parent vnode that does not exist. For
example, if the large vnode index contains a maximum vnode of 2901, any
parent vnode encountered that is larger than 2901 will result in an
out-of-bounds reference to our vnode essence array, leading to a
segfault or undefined behavior.
Modify the logic to check for out-of-bounds parent vnodes, and log them
rather than segfaulting.
Change-Id: I49f53935830fbb428fe0bff04c33248d3806a4b2
Reviewed-on: https://gerrit.openafs.org/14385
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Andrew Deason <adeason@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>