From: xie xingguo Date: Mon, 4 Jan 2016 04:15:42 +0000 (+0800) Subject: os:fix wrongly placed assert X-Git-Tag: v10.0.3~31^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=9fe0ddef6746b5d387780e8a51b0d46d9e2389c1;p=ceph.git os:fix wrongly placed assert At present it will not be able to dump the current opened fds when an EMFILE error has encountered. Fixes: #14176 Signed-off-by: xie xingguo --- diff --git a/src/os/keyvaluestore/KeyValueStore.cc b/src/os/keyvaluestore/KeyValueStore.cc index 03c663a4feb4..2b0635808c8f 100644 --- a/src/os/keyvaluestore/KeyValueStore.cc +++ b/src/os/keyvaluestore/KeyValueStore.cc @@ -1589,11 +1589,12 @@ unsigned KeyValueStore::_do_transaction(Transaction& transaction, f.close_section(); f.flush(*_dout); *_dout << dendl; - assert(0 == "unexpected error"); if (r == -EMFILE) { dump_open_fds(g_ceph_context); - } + } + + assert(0 == "unexpected error"); } }