]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE14-linux-kmem-destroy-fix-20070609
authorDerrick Brashear <shadow@dementia.org>
Sun, 10 Jun 2007 06:40:45 +0000 (06:40 +0000)
committerDerrick Brashear <shadow@dementia.org>
Sun, 10 Jun 2007 06:40:45 +0000 (06:40 +0000)
don't destroy if create failed

(cherry picked from commit 18484f0fc64a550c1abacb6d2614c7ea12af4052)

src/afs/LINUX/osi_vfsops.c

index f8ec546bd08d0e0477866cc5f055f7bd31b47ee0..c5501db3edc4a9c8238b9d19a05fabcf9019b0ee 100644 (file)
@@ -316,7 +316,8 @@ afs_init_inodecache(void)
 void
 afs_destroy_inodecache(void)
 {
-    (void) kmem_cache_destroy(afs_inode_cachep);
+    if (afs_inode_cachep)
+       (void) kmem_cache_destroy(afs_inode_cachep);
 }
 #else
 int