Commit f77a1e45 authored by Michal 'vorner' Vaner's avatar Michal 'vorner' Vaner
Browse files

[1944] Make sure we print the message ID on abort

When we enable the strict log checking and the excess placeholders check
triggers, we need to print the message to easily identify the message ID
with the problem.
parent eacdcb43
......@@ -17,6 +17,10 @@
#include <cassert>
#ifdef ENABLE_LOGGER_CHECKS
#include <iostream>
#endif
using namespace std;
using namespace boost;
......@@ -59,6 +63,9 @@ checkExcessPlaceholders(string* message, unsigned int placeholder) {
// but we can't at least for now because this function is called from
// the Formatter's destructor.
#ifdef ENABLE_LOGGER_CHECKS
// Also, make sure we print the message so we can identify which
// identifier has the problem.
cerr << "Message " << *message << endl;
assert("Excess logger placeholders still exist in message" == NULL);
#else
message->append(" @@Excess logger placeholders still exist@@");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment