storaged: fix regression found in unit-test

Should use reference instead of copy to clear storaged proto

Bug: 63740245
Change-Id: Ibb933a0bac12508467fc104b37e7cc490dfbe948
This commit is contained in:
Jin Qian 2017-11-03 14:08:11 -07:00
parent 4b7f0fdccb
commit 65d8c03d35

View file

@ -407,7 +407,7 @@ void get_io_usage_proto(io_usage* usage, const IOUsage& io_proto)
void uid_monitor::update_uid_io_proto(unordered_map<int, StoragedProto>* protos)
{
for (auto it : *protos) {
for (auto& it : *protos) {
it.second.mutable_uid_io_usage()->Clear();
}