]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
STABLE14-avoid-assert-for-missing-vnodes-20060921
authorDerrick Brashear <shadow@dementia.org>
Thu, 21 Sep 2006 12:49:25 +0000 (12:49 +0000)
committerDerrick Brashear <shadow@dementia.org>
Thu, 21 Sep 2006 12:49:25 +0000 (12:49 +0000)
right now if a vnode is missing when we try to clone, we could assert. ick.

(cherry picked from commit b613480bd5eb6bc2a14c4e23229d90105291944c)

src/vol/clone.c

index 1a02d2d266b683a3a42dbb4216cbfd976aa0cf30..aedee9ecece211c38a504a6716fb6e09ac94d546 100644 (file)
@@ -256,7 +256,8 @@ DoCloneIndex(Volume * rwvp, Volume * clvp, VnodeClass class, int reclone)
                    Log("IH_INC failed: %x, %s, %u errno %d\n",
                        V_linkHandle(rwvp), PrintInode(NULL, rwinode),
                        V_parentId(rwvp), errno);
-                   assert(0);
+                   VForceOffline_r(rwvp);
+                   ERROR_EXIT(EIO);
                }
                inodeinced = 1;
            }
@@ -308,7 +309,8 @@ DoCloneIndex(Volume * rwvp, Volume * clvp, VnodeClass class, int reclone)
                    Log("IH_DEC failed: %x, %s, %u errno %d\n",
                        V_linkHandle(rwvp), PrintInode(NULL, rwinode),
                        V_parentId(rwvp), errno);
-                   assert(0);
+                   VForceOffline_r(rwvp);
+                   ERROR_EXIT(EIO);
                }
            }
            /* And if the directory was marked clone, unmark it */