From 8b6fa652627b4e978f89383e2d5efe7aaef9f9b0 Mon Sep 17 00:00:00 2001 From: Greg Farnum Date: Thu, 11 Jun 2009 16:23:26 -0700 Subject: [PATCH] uClient: Fixed a copying error and a double lock. --- src/client/Client.cc | 1 - src/osdc/Objecter.cc | 6 +++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/client/Client.cc b/src/client/Client.cc index 1eb77c74d59b0..dea62357915ed 100644 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@ -4008,7 +4008,6 @@ int Client::statfs(const char *path, struct statvfs *stbuf) int Client::ll_statfs(vinodeno_t vino, struct statvfs *stbuf) { - Mutex::Locker lock(client_lock); tout << "ll_statfs" << std::endl; return statfs(0, stbuf); } diff --git a/src/osdc/Objecter.cc b/src/osdc/Objecter.cc index 3fedb3a4b3c9e..35e6e4a0862dd 100644 --- a/src/osdc/Objecter.cc +++ b/src/osdc/Objecter.cc @@ -704,7 +704,11 @@ void Objecter::handle_fs_stats_reply(MStatfsReply *m) { if (op_statfs.count(tid)) { StatfsOp *op = op_statfs[tid]; dout(10) << "have request " << tid << " at " << op << dendl; - op->stats = &(m->h.st); + *(op->stats) = m->h.st; + /*op->stats->f_total = m->h.st.f_total; + op->stats->f_free = m->h.st.f_free; + op->stats->f_avail = m->h.st.f_avail; + op->stats->f_objects = m->h.st.f_objects;*/ op->onfinish->finish(0); delete op->onfinish; op_statfs.erase(tid); -- 2.39.5