-------------------------------------------------------------------------
| 128 | |
| 129 | //------------------------------------------------------------------------- |
| 130 | IDebugEventsHandler::ExceptionType CodeCoverageRunner::OnException( |
| 131 | HANDLE hProcess, |
| 132 | HANDLE hThread, |
| 133 | const EXCEPTION_DEBUG_INFO& exceptionDebugInfo) |
| 134 | { |
| 135 | std::wostringstream ostr; |
| 136 | |
| 137 | auto status = exceptionHandler_->HandleException(hProcess, exceptionDebugInfo, ostr); |
| 138 | |
| 139 | switch (status) |
| 140 | { |
| 141 | case CppCoverage::ExceptionHandlerStatus::BreakPoint: |
| 142 | { |
| 143 | if (OnBreakPoint(exceptionDebugInfo, hProcess, hThread)) |
| 144 | return IDebugEventsHandler::ExceptionType::BreakPoint; |
| 145 | return IDebugEventsHandler::ExceptionType::InvalidBreakPoint; |
| 146 | } |
| 147 | case CppCoverage::ExceptionHandlerStatus::FirstChanceException: |
| 148 | { |
| 149 | return IDebugEventsHandler::ExceptionType::NotHandled; |
| 150 | } |
| 151 | case CppCoverage::ExceptionHandlerStatus::Error: |
| 152 | { |
| 153 | LOG_ERROR << ostr.str(); |
| 154 | |
| 155 | return IDebugEventsHandler::ExceptionType::Error; |
| 156 | } |
| 157 | case CppCoverage::ExceptionHandlerStatus::CppError: |
| 158 | { |
| 159 | LOG_ERROR << ostr.str(); |
| 160 | |
| 161 | return IDebugEventsHandler::ExceptionType::CppError; |
| 162 | } |
| 163 | } |
| 164 | |
| 165 | return IDebugEventsHandler::ExceptionType::NotHandled; |
| 166 | } |
| 167 | |
| 168 | //------------------------------------------------------------------------- |
| 169 | bool CodeCoverageRunner::OnBreakPoint( |
nothing calls this directly
no test coverage detected