vol: A GOING_OFFLINE volume should yield VOFFLINE
authorAndrew Deason <adeason@sinenomine.net>
Fri, 27 Apr 2012 17:59:25 +0000 (12:59 -0500)
committerDerrick Brashear <shadow@dementix.org>
Sat, 28 Apr 2012 04:46:34 +0000 (21:46 -0700)
commitd10f71d44fddd7ea6e37481cffd7ee1be2a93217
treef84542fa60c133c1804837c630c82fe48f93df59
parent868378cc00b9ac7016da3dc457abf3fa2016687c
vol: A GOING_OFFLINE volume should yield VOFFLINE

Currently, GetVolume treats a volume in the VOL_STATE_GOING_OFFLINE
state the same as VOL_STATE_SHUTTING_DOWN, and so returns VNOVOL for a
GOING_OFFLINE volume, but these states are very different.

GOING_OFFLINE indicates that a volume should soon be in the UNATTACHED
state, so we should treat GOING_OFFLINE the same as UNATTACHED for
returning errors to the user. For UNATTACHED, we return specialStatus
if it's set, or VOFFLINE otherwise; so, just do the same for
GOING_OFFLINE.

Change-Id: Ia9500d2cfd90b8c15782a06025f39298810d0a99
Reviewed-on: http://gerrit.openafs.org/7290
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
src/vol/volume.c