1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

feat(logging): Hide toxcore spam when using IPv4

This commit is contained in:
Anthony Bilinski 2022-03-07 23:30:02 -08:00
parent a96deb7bc0
commit ac4f01cf7f
No known key found for this signature in database
GPG Key ID: 2AA8E0DA1B31FB3C

View File

@ -94,6 +94,11 @@ void logMessageHandler(QtMsgType type, const QMessageLogContext& ctxt, const QSt
&& msg == QString("QFSFileEngine::open: No file name specified"))
return;
if (msg == QString("attempted to send message with network family 10 (probably IPv6) on IPv4 socket")) {
// non-stop c-toxcore spam for IPv4 users: https://github.com/TokTok/c-toxcore/issues/1432
return;
}
QRegExp snoreFilter{QStringLiteral("Snore::Notification.*was already closed")};
if (type == QtWarningMsg
&& msg.contains(snoreFilter))