From 11be8ed005e545c70d8413e2419a3196bf88d829 Mon Sep 17 00:00:00 2001 From: Koncord Date: Sun, 18 Dec 2016 12:48:23 +0800 Subject: [PATCH] Rename copyOldLog to renameOldLog --- apps/openmw-mp/main.cpp | 2 +- apps/openmw/main.cpp | 2 +- components/openmw-mp/Log.cpp | 2 +- components/openmw-mp/Log.hpp | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/openmw-mp/main.cpp b/apps/openmw-mp/main.cpp index 7ab6c1cbf..e3a4860f6 100644 --- a/apps/openmw-mp/main.cpp +++ b/apps/openmw-mp/main.cpp @@ -171,7 +171,7 @@ int main(int argc, char *argv[]) boost::filesystem::ofstream logfile; // Redirect cout and cerr to openmw.log - cout << Log::copyOldLog(cfgMgr.getLogPath(), "server", "log") << endl; + cout << Log::renameOldLog(cfgMgr.getLogPath(), "server", "log") << endl; logfile.open (boost::filesystem::path(cfgMgr.getLogPath() / "/server.log")); diff --git a/apps/openmw/main.cpp b/apps/openmw/main.cpp index f24136dda..ba18c78cf 100644 --- a/apps/openmw/main.cpp +++ b/apps/openmw/main.cpp @@ -335,7 +335,7 @@ int main(int argc, char**argv) std::cerr.rdbuf (&sb); #else // Redirect cout and cerr to openmw.log - Log::copyOldLog(cfgMgr.getLogPath(), "openmw", "log"); + Log::renameOldLog(cfgMgr.getLogPath(), "openmw", "log"); logfile.open (boost::filesystem::path(cfgMgr.getLogPath() / "/openmw.log")); coutsb.open (Tee(logfile, oldcout)); diff --git a/components/openmw-mp/Log.cpp b/components/openmw-mp/Log.cpp index 624080c25..4d2d67417 100644 --- a/components/openmw-mp/Log.cpp +++ b/components/openmw-mp/Log.cpp @@ -106,7 +106,7 @@ void Log::print(int level, bool hasPrefix, const char *file, int line, const cha cout << buf.data() << flush; } -string Log::copyOldLog(boost::filesystem::path path, string name, string extension) +string Log::renameOldLog(boost::filesystem::path path, string name, string extension) { namespace fs = boost::filesystem; fs::directory_iterator end_iter; diff --git a/components/openmw-mp/Log.hpp b/components/openmw-mp/Log.hpp index bd9bed0d7..02573b44c 100644 --- a/components/openmw-mp/Log.hpp +++ b/components/openmw-mp/Log.hpp @@ -47,7 +47,7 @@ public: static void SetLevel(int level); void print(int level, bool hasPrefix, const char *file, int line, const char *message, ...) const; - static std::string copyOldLog(boost::filesystem::path path, std::string name, std::string extension); + static std::string renameOldLog(boost::filesystem::path path, std::string name, std::string extension); private: Log(int logLevel); /// Not implemented