diff --git a/src/utils/macros.h b/src/utils/macros.h index 7cb4670f7..142b7f9c5 100644 --- a/src/utils/macros.h +++ b/src/utils/macros.h @@ -104,7 +104,7 @@ extern const char* g_death_file; #include #ifdef NDEBUG -#define HASSERT(x) do { if (!(x)) { fprintf(stderr, "Assertion failed in file " __FILE__ " line %d: assert(" #x ")", __LINE__); g_death_file = __FILE__; g_death_lineno = __LINE__; abort();} } while(0) +#define HASSERT(x) do { if (!(x)) { fprintf(stderr, "Assertion failed in file " __FILE__ " line %d: assert(" #x ")\n", __LINE__); g_death_file = __FILE__; g_death_lineno = __LINE__; abort();} } while(0) #else /// Checks that the value of expression x is true, else terminates the current /// process. @@ -114,7 +114,7 @@ extern const char* g_death_file; /// Unconditionally terminates the current process with a message. /// @param MSG is the message to print as cause of death. -#define DIE(MSG) do { fprintf(stderr, "Crashed in file " __FILE__ " line %d: " MSG, __LINE__); g_death_file = __FILE__; g_death_lineno = __LINE__; abort(); } while(0) +#define DIE(MSG) do { fprintf(stderr, "Crashed in file " __FILE__ " line %d: " MSG "\n", __LINE__); g_death_file = __FILE__; g_death_lineno = __LINE__; abort(); } while(0) #endif