afs_AllocDCache: return NULL instead of panic
authorAndrew Deason <adeason@sinenomine.net>
Thu, 1 Nov 2012 20:32:31 +0000 (15:32 -0500)
committerDerrick Brashear <shadow@your-file-system.com>
Tue, 13 Nov 2012 18:38:20 +0000 (10:38 -0800)
commit64ee7b32f134e6431eb2894ed4397f8b1fea25ad
tree928650db569f8155d615dd0b0cb7769e7a4bf6c6
parent336939179721d79a6798614ff747dd06701e3edc
afs_AllocDCache: return NULL instead of panic

Currently afs_AllocDCache will panic if we cannot get a valid dcache
from the free/discard lists. Instead, return NULL, so the caller can
decide how to handle the error.

Currently the caller will just panic anyway, but that will be
addressed in a future commit.

Change-Id: Iafb539bbda9ef20907ef575699185f111ca39c2b
Reviewed-on: http://gerrit.openafs.org/8377
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
src/afs/afs_dcache.c