Merge pull request #10191 from batrick/mds-minor

mds: use reference to avoid copy

Reviewed-by: John Spray <john.spray@redhat.com>
This commit is contained in:
John Spray 2016-07-13 12:41:01 +01:00 committed by GitHub
commit 275b729336

View File

@ -274,7 +274,7 @@ void FSMap::encode(bufferlist& bl, uint64_t features) const
// mds_info with the standbys to get a pre-jewel-style mon MDSMap.
MDSMap full_mdsmap = fs->mds_map;
full_mdsmap.epoch = epoch;
for (const auto p : standby_daemons) {
for (const auto &p : standby_daemons) {
full_mdsmap.mds_info[p.first] = p.second;
}