diff options
author | Chris Wilson <chris+github@qwirx.com> | 2012-11-17 19:59:51 +0000 |
---|---|---|
committer | Chris Wilson <chris+github@qwirx.com> | 2012-11-17 19:59:51 +0000 |
commit | 69147089fa278f1225ae5fb29c87a59009dcc900 (patch) | |
tree | aecf170d7af6acaf909b161b094dc8bf023b48b9 /lib/common/Logging.h | |
parent | 1098297e0acfb37715336f1bbd8cfe548a6e038e (diff) |
Fix duplicate tagging of housekeeping messages.
Diffstat (limited to 'lib/common/Logging.h')
-rw-r--r-- | lib/common/Logging.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/lib/common/Logging.h b/lib/common/Logging.h index 574677f1..81062e38 100644 --- a/lib/common/Logging.h +++ b/lib/common/Logging.h @@ -346,15 +346,24 @@ class Logging std::string mOldTag; public: + Tagger() + : mOldTag(Logging::GetProgramName()) + { + } Tagger(const std::string& rTempTag) + : mOldTag(Logging::GetProgramName()) { - mOldTag = Logging::GetProgramName(); Logging::SetProgramName(mOldTag + " " + rTempTag); } ~Tagger() { Logging::SetProgramName(mOldTag); } + + void Change(const std::string& newTempTag) + { + Logging::SetProgramName(mOldTag + " " + newTempTag); + } }; }; |