| 145 | } |
| 146 | |
| 147 | static void HandleTerminatedProcess( |
| 148 | ProcessInfo* processInfo) |
| 149 | { |
| 150 | auto const& args = GetCommandLineArgs(); |
| 151 | |
| 152 | if (processInfo->mIsTargetProcess) { |
| 153 | // Close this process' CSV. |
| 154 | CloseMultiCsv(processInfo); |
| 155 | |
| 156 | // Quit if this is the last process tracked for --terminate_on_proc_exit. |
| 157 | gTargetProcessCount -= 1; |
| 158 | if (args.mTerminateOnProcExit && gTargetProcessCount == 0) { |
| 159 | ExitMainThread(); |
| 160 | } |
| 161 | } |
| 162 | } |
| 163 | |
| 164 | static void ProcessProcessEvent( |
| 165 | ProcessEvent const& processEvent) |
no test coverage detected