diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2024-07-08 09:53:24 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2024-07-08 08:57:25 +0000 |
| commit | e03bdbc0e5550821e70d48113e1b3a12c913cc36 (patch) | |
| tree | 663760605085b943841ece5aa6e6959effe26c65 /executor/executor_runner.h | |
| parent | 845ac4781cad8630bd75de08857b8e81198d3554 (diff) | |
executor: repair debug mode
Don't print SYZFAIL messages during machine check.
Otherwise each of them is detected as a bug.
Diffstat (limited to 'executor/executor_runner.h')
| -rw-r--r-- | executor/executor_runner.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/executor/executor_runner.h b/executor/executor_runner.h index 992227787..a688fa5e1 100644 --- a/executor/executor_runner.h +++ b/executor/executor_runner.h @@ -443,7 +443,14 @@ private: } if (flag_debug) { output_.resize(output_.size() + 1); - debug("proc %d: got output: %s\n", id_, output_.data() + debug_output_pos_); + const char* output = reinterpret_cast<char*>(output_.data()) + debug_output_pos_; + // During machine check we can execute some requests that legitimately fail. + // These requests have ReturnError flag, so that the failure is returned + // to the caller for analysis. Don't print SYZFAIL in these requests, + // otherwise it will be detected as a bug. + if (msg_ && IsSet(msg_->flags, rpc::RequestFlag::ReturnError) && strstr(output, "SYZFAIL")) + output = "REDACTED-CONTAINS-FAIL"; + debug("proc %d: got output: %s\n", id_, output); output_.resize(output_.size() - 1); debug_output_pos_ = output_.size(); } |
