better abort in internal_logging.cc:Log
We use __builtin_trap (which compiles to explicitly undefined instruction or "int 3" on x64-en), when available, to make those crashing Log invokations a little nicer to debug.
This commit is contained in:
parent
a6864ae233
commit
65ce9e899e
|
@ -92,6 +92,12 @@ void Log(LogMode mode, const char* filename, int line,
|
|||
|
||||
WriteMessage(state.buf_, msglen);
|
||||
|
||||
#if defined(__has_builtin)
|
||||
#if __has_builtin(__builtin_trap)
|
||||
__builtin_trap();
|
||||
#endif
|
||||
#endif // defined(__has_builtin)
|
||||
|
||||
abort();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue