]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: don't choke on path_traverse_to_dir that fully exists
authorSage Weil <sage@newdream.net>
Fri, 26 Jun 2009 23:50:00 +0000 (16:50 -0700)
committerSage Weil <sage@newdream.net>
Tue, 30 Jun 2009 19:33:00 +0000 (12:33 -0700)
src/mds/MDCache.cc

index 8141f6d990e4db2d1ffd69a77ec31d59ad011997..6e80413cbac3acbe1843141e5726f5d890744c45 100644 (file)
@@ -5857,8 +5857,8 @@ bool MDCache::path_is_mine(filepath& path)
  *
  * @path - path to traverse (as far as we can)
  *
- * assumes we _don't_ have the full path.  (if we do, we throw an assertion.)
- * assumes that we are path for the path (we open dirfrags willy-nilly).
+ * usually we _don't_ have the full path.  (if we do, we return NULL.)
+ * also, if path calls a file a dir, we return NULL.
  */
 CDir *MDCache::path_traverse_to_dir(filepath& path)
 {
@@ -5878,8 +5878,9 @@ CDir *MDCache::path_traverse_to_dir(filepath& path)
     assert(dnl->is_primary());
     cur = dnl->get_inode();
   }
-  assert(0);
-  //return NULL; // oh, we have the full path.
+
+  // hmm, we DO have the full path.
+  return NULL;
 }