]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
cfuse: remove unneeded loop.
authorGreg Farnum <gregory.farnum@dreamhost.com>
Thu, 27 Oct 2011 23:05:00 +0000 (16:05 -0700)
committerGreg Farnum <gregory.farnum@dreamhost.com>
Thu, 27 Oct 2011 23:15:32 +0000 (16:15 -0700)
The only time this was looping previously was completely unnecessary
anyway, as 1 meant the same thing as 0: there are no more dentries
remaining.

Signed-off-by: Greg Farnum <gregory.farnum@dreamhost.com>
src/client/fuse_ll.cc

index aeaceec3f107a143bb37f71629dac2e67d282b86..2c766c22f96af1b949a6acc5cee4aa252b9465ce 100644 (file)
@@ -421,9 +421,7 @@ static void ceph_ll_readdir(fuse_req_t req, fuse_ino_t ino, size_t size,
   rc.snap = fino_snap(ino);
 
   int r;
-  do {
-    r = client->readdir_r_cb(dirp, ceph_ll_add_dirent, &rc);
-  } while (r > 0);
+  r = client->readdir_r_cb(dirp, ceph_ll_add_dirent, &rc);
 
   fuse_reply_buf(req, rc.buf, rc.pos);
   delete[] rc.buf;