From: xie xingguo Date: Fri, 8 Apr 2016 02:03:37 +0000 (+0800) Subject: osd: fix indention, typo etc. X-Git-Tag: v11.0.0~782^2~5 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=10898dfbeb2a4628ebd689d0b5acdfa281a3dac9;p=ceph.git osd: fix indention, typo etc. Signed-off-by: xie xingguo --- diff --git a/src/osd/PG.cc b/src/osd/PG.cc index 44cc1c7719b8..33740739a49e 100644 --- a/src/osd/PG.cc +++ b/src/osd/PG.cc @@ -7819,13 +7819,13 @@ PG::PriorSet::PriorSet(bool ec_pool, // but because we want their pg_info to inform choose_acting(), and // so that we know what they do/do not have explicitly before // sending them any new info/logs/whatever. - for (unsigned i=0; iis_up(o)) { - dout(10) << "affected_by_map osd." << *p << " now up" << dendl; + dout(10) << "affected_by_map osd." << o << " now up" << dendl; return true; } @@ -7957,8 +7957,8 @@ bool PG::PriorSet::affected_by_map(const OSDMapRef osdmap, const PG *debug_pg) c map::const_iterator r = blocked_by.find(o); if (r != blocked_by.end()) { if (osdmap->get_info(o).lost_at != r->second) { - dout(10) << "affected_by_map osd." << o << " (re)marked as lost" << dendl; - return true; + dout(10) << "affected_by_map osd." << o << " (re)marked as lost" << dendl; + return true; } } } diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index 800dba6ef3d3..0482db7fbd4c 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -420,7 +420,7 @@ void ReplicatedPG::wait_for_all_missing(OpRequestRef op) bool ReplicatedPG::is_degraded_or_backfilling_object(const hobject_t& soid) { /* The conditions below may clear (on_local_recover, before we queue - * the tranasction) before we actually requeue the degraded waiters + * the transaction) before we actually requeue the degraded waiters * in on_global_recover after the transaction completes. */ if (waiting_for_degraded_object.count(soid)) @@ -578,7 +578,7 @@ bool PGLSParentFilter::filter(const hobject_t &obj, vector::iterator vi; for (vi = bt.ancestors.begin(); vi != bt.ancestors.end(); ++vi) { generic_dout(0) << "vi->dirino=" << vi->dirino << " parent_ino=" << parent_ino << dendl; - if ( vi->dirino == parent_ino) { + if (vi->dirino == parent_ino) { ::encode(*vi, outdata); return true; } @@ -680,7 +680,7 @@ int ReplicatedPG::get_pgls_filter(bufferlist::iterator& iter, PGLSFilter **pfilt } else { // Successfully constructed and initialized, return it. *pfilter = filter; - return 0; + return 0; } } @@ -830,7 +830,6 @@ int ReplicatedPG::do_command( { f->open_array_section("objects"); int32_t num = 0; - bufferlist bl; for (; p != needs_recovery_map.end() && num < cct->_conf->osd_command_max_records; ++p) { if (missing_loc.is_unfound(p->first)) { f->open_object_section("object"); @@ -855,7 +854,7 @@ int ReplicatedPG::do_command( } f->close_section(); } - f->dump_int("more", p != needs_recovery_map.end()); + f->dump_bool("more", p != needs_recovery_map.end()); f->close_section(); f->flush(odata); return 0; @@ -1422,7 +1421,7 @@ ReplicatedPG::ReplicatedPG(OSDService *o, OSDMapRef curmap, PGBackend::build_pg_backend( _pool.info, curmap, this, coll_t(p), ch, o->store, cct)), object_contexts(o->cct, g_conf->osd_pg_object_context_cache_count), - snapset_contexts_lock("ReplicatedPG::snapset_contexts"), + snapset_contexts_lock("ReplicatedPG::snapset_contexts_lock"), backfills_in_flight(hobject_t::Comparator(true)), pending_backfill_updates(hobject_t::Comparator(true)), new_backfill(false),