Browse Source

feat(logging): Hide toxcore spam when using IPv4

reviewable/pr6537/r1
Anthony Bilinski 3 years ago
parent
commit
ac4f01cf7f
No known key found for this signature in database
GPG Key ID: 2AA8E0DA1B31FB3C
  1. 5
      src/main.cpp

5
src/main.cpp

@ -94,6 +94,11 @@ void logMessageHandler(QtMsgType type, const QMessageLogContext& ctxt, const QSt @@ -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))

Loading…
Cancel
Save