diff mbox

cmds segfault on pdj-fstest (ceph.git unstable)

Message ID AANLkTikoEestUHujD0_TcG0haFOcOX4pYPVodpr6NOKF@mail.gmail.com (mailing list archive)
State New, archived
Headers show

Commit Message

Henry C Chang June 10, 2010, 11:38 a.m. UTC
None
diff mbox

Patch

===========================================
diff --git a/src/mds/Server.cc b/src/mds/Server.cc
index 29d0a32..4a90f4e 100644
--- a/src/mds/Server.cc
+++ b/src/mds/Server.cc
@@ -3976,7 +3976,6 @@  bool Server::_dir_is_nonempty(MDRequest *mdr, CInode *in)
               << dir->inode->get_projected_inode()->dirstat.size()
               << " on " << *dir->inode
               << dendl;
-      reply_request(mdr, -ENOTEMPTY);
       return true;
     }

@@ -4070,8 +4069,10 @@  void Server::handle_client_rename(MDRequest *mdr)
     }

     // non-empty dir?
-    if (oldin->is_dir() && _dir_is_nonempty(mdr, oldin))
+    if (oldin->is_dir() && _dir_is_nonempty(mdr, oldin)) {
+      reply_request(mdr, -ENOTEMPTY);
       return;
+    }
   }

   // -- some sanity checks --