From f5fc51a63b28bf17de43000947c291db3cd5ebe3 Mon Sep 17 00:00:00 2001 From: James Lu Date: Wed, 13 Dec 2017 20:21:21 -0500 Subject: [PATCH] src/Client: send failed logins to NOTICE instead of PRIVMSG When connecting to many ZNC networks at once, one failed login causes numerous query windows from *status to pop up. These can be annoying to close depending on the client. --- src/Client.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/Client.cpp b/src/Client.cpp index 93e8e595..6b7b7991 100644 --- a/src/Client.cpp +++ b/src/Client.cpp @@ -368,10 +368,9 @@ void CAuthBase::RefuseLogin(const CString& sReason) { // login. Use sReason because there are other reasons than "wrong // password" for a login to be rejected (e.g. fail2ban). if (pUser) { - pUser->PutStatus("A client from [" + GetRemoteIP() + - "] attempted " - "to login as you, but was rejected [" + - sReason + "]."); + pUser->PutStatusNotice("A client from [" + GetRemoteIP() + "] attempted " + "to login as you, but was rejected [" + + sReason + "]."); } GLOBALMODULECALL(OnFailedLogin(GetUsername(), GetRemoteIP()), NOTHING);