Ninja: msvc6 for-scoping

This commit is contained in:
Peter Kuemmel 2012-06-16 12:51:25 +02:00
parent 44b9bbc89d
commit f2c12887ba
1 changed files with 7 additions and 7 deletions

View File

@ -448,17 +448,17 @@ Subprocess* SubprocessSet::NextFinished() {
}
void SubprocessSet::Clear() {
for (std::vector<Subprocess*>::iterator i = running_.begin();
i != running_.end(); ++i) {
if ((*i)->child_.hProcess) {
std::vector<Subprocess*>::iterator it = running_.begin();
for (; it != running_.end(); ++it) {
if ((*it)->child_.hProcess) {
if (!GenerateConsoleCtrlEvent(CTRL_BREAK_EVENT,
(*i)->child_.dwProcessId))
(*it)->child_.dwProcessId))
Win32Fatal("GenerateConsoleCtrlEvent");
}
}
for (std::vector<Subprocess*>::iterator i = running_.begin();
i != running_.end(); ++i)
delete *i;
it = running_.begin();
for (; it != running_.end(); ++it)
delete *it;
running_.clear();
}