Fix a cd bug that prevented users from changing dirs with the shell module.

git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@1401 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
silverleo
2009-02-27 15:53:38 +00:00
parent b0f94ba49c
commit ef22c446df

View File

@@ -70,7 +70,7 @@ public:
virtual void OnModCommand(const CString& sLine) {
CString sCommand = sLine.Token(0);
if (sCommand.Equals("cd")) {
CString sArg = sCommand.Token(1, true);
CString sArg = sLine.Token(1, true);
CString sPath = CDir::ChangeDir(m_sPath, (sArg.empty() ? CString(CZNC::Get().GetHomePath()) : sArg), CZNC::Get().GetHomePath());
CFile Dir(sPath);