[Development] qt_message_fatal() in Linux

andrea mariofutire at googlemail.com
Tue Nov 21 21:54:47 CET 2017


I've had a crash today because of a mismatch between .so versions.

Solution was easy

https://bugzilla.redhat.com/show_bug.cgi?id=1515922

but in doing so I realised that in Linux the function

static void qt_message_fatal(QtMsgType, const QMessageLogContext &context, const QString &message)

in qlogging.cpp:1686 is just a call to

std::abort().

In VisualStudio in Debug it prints the error message.

Since we are about to call abort, why not just print the message to stderr in all cases?

It makes a big difference if the crash says something about the reason behind it.
Especially for people without a debugger.

Andrea




More information about the Development mailing list