Improve logging on failed check.

GitOrigin-RevId: 3058af6fe76779e02eb6440fd1ab13ce07621785
This commit is contained in:
levlam 2020-03-14 01:54:13 +03:00
parent 3d85a7f304
commit 1ed0ab3146

View File

@ -39,11 +39,10 @@ void TlParser::set_error(const string &error_message) {
left_len = 0;
data_len = 0;
} else {
LOG_CHECK(error_pos != std::numeric_limits<size_t>::max() && data_len == 0 && left_len == 0)
<< data_len << " " << left_len << " " << data << " " << &empty_data[0] << " " << error_pos << " " << error
<< " " << data << " " << &empty_data;
data = empty_data;
CHECK(error_pos != std::numeric_limits<size_t>::max());
LOG_CHECK(data_len == 0) << data_len << " " << left_len << " " << data << " " << &empty_data[0] << " " << error_pos
<< " " << error;
CHECK(left_len == 0);
}
}