summaryrefslogtreecommitdiffstats
path: root/src/Protocol/Protocol18x.cpp
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2015-01-25 17:06:15 +0100
committerMattes D <github@xoft.cz>2015-01-27 14:53:34 +0100
commit1b9c0f1030ec212eb39c5291f44d99313a2b638d (patch)
tree80fdf2912fa17c882697214d96c23a53051f8721 /src/Protocol/Protocol18x.cpp
parentFixed enchant packet handling. (diff)
downloadcuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.tar
cuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.tar.gz
cuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.tar.bz2
cuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.tar.lz
cuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.tar.xz
cuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.tar.zst
cuberite-1b9c0f1030ec212eb39c5291f44d99313a2b638d.zip
Diffstat (limited to '')
-rw-r--r--src/Protocol/Protocol18x.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Protocol/Protocol18x.cpp b/src/Protocol/Protocol18x.cpp
index 5d722d9fc..7d954a297 100644
--- a/src/Protocol/Protocol18x.cpp
+++ b/src/Protocol/Protocol18x.cpp
@@ -108,10 +108,12 @@ cProtocol180::cProtocol180(cClientHandle * a_Client, const AString & a_ServerAdd
{
static int sCounter = 0;
cFile::CreateFolder("CommLogs");
+ AString IP(a_Client->GetIPString());
+ ReplaceString(IP, ":", "_");
AString FileName = Printf("CommLogs/%x_%d__%s.log",
static_cast<unsigned>(time(nullptr)),
sCounter++,
- cFile::ReplaceFileNameInvalidChars(a_Client->GetIPString()).c_str()
+ IP.c_str()
);
if (!m_CommLogFile.Open(FileName, cFile::fmWrite))
{