mirror of
https://github.com/znc/znc.git
synced 2026-03-28 17:42:41 +01:00
[log] $WINDOW should be last because it could contain %
Thanks to @NuclearW for spotting
This commit is contained in:
@@ -84,9 +84,9 @@ void CLogMod::PutLog(const CString& sLine, const CString& sWindow /*= "Status"*/
|
||||
|
||||
// TODO: Properly handle IRC case mapping
|
||||
// $WINDOW has to be handled last, since it can contain %
|
||||
sPath.Replace("$USER", CString((m_pUser ? m_pUser->GetUserName() : "UNKNOWN")).AsLower());
|
||||
sPath.Replace("$NETWORK", CString((m_pNetwork ? m_pNetwork->GetName() : "znc")).AsLower());
|
||||
sPath.Replace("$WINDOW", CString(sWindow.Replace_n("/", "-").Replace_n("\\", "-")).AsLower());
|
||||
sPath.Replace("$USER", CString((m_pUser ? m_pUser->GetUserName() : "UNKNOWN")).AsLower());
|
||||
|
||||
// Check if it's allowed to write in this specific path
|
||||
sPath = CDir::CheckPathPrefix(GetSavePath(), sPath);
|
||||
|
||||
Reference in New Issue
Block a user