diff options
Diffstat (limited to 'runtime/monitor.cc')
| -rw-r--r-- | runtime/monitor.cc | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/runtime/monitor.cc b/runtime/monitor.cc index 48c05692b4..ff193c9534 100644 --- a/runtime/monitor.cc +++ b/runtime/monitor.cc @@ -979,9 +979,7 @@ void MonitorList::Add(Monitor* m) { void MonitorList::SweepMonitorList(IsMarkedTester is_marked, void* arg) { MutexLock mu(Thread::Current(), monitor_list_lock_); - typedef std::list<Monitor*>::iterator It; // TODO: C++0x auto - It it = list_.begin(); - while (it != list_.end()) { + for (auto it = list_.begin(); it != list_.end(); ) { Monitor* m = *it; if (!is_marked(m->GetObject(), arg)) { VLOG(monitor) << "freeing monitor " << m << " belonging to unmarked object " << m->GetObject(); |