mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 03:37:49 +02:00
fix code syle(spaces->tabs, tabulations)
Signed-off-by: R4SAS <r4sas@i2pmail.org>
This commit is contained in:
parent
9633c247f0
commit
7a5146ea74
115 changed files with 3206 additions and 3161 deletions
|
@ -110,18 +110,18 @@ namespace log {
|
|||
}
|
||||
}
|
||||
|
||||
std::string str_tolower(std::string s) {
|
||||
std::transform(s.begin(), s.end(), s.begin(),
|
||||
// static_cast<int(*)(int)>(std::tolower) // wrong
|
||||
// [](int c){ return std::tolower(c); } // wrong
|
||||
// [](char c){ return std::tolower(c); } // wrong
|
||||
[](unsigned char c){ return std::tolower(c); } // correct
|
||||
);
|
||||
return s;
|
||||
}
|
||||
std::string str_tolower(std::string s) {
|
||||
std::transform(s.begin(), s.end(), s.begin(),
|
||||
// static_cast<int(*)(int)>(std::tolower) // wrong
|
||||
// [](int c){ return std::tolower(c); } // wrong
|
||||
// [](char c){ return std::tolower(c); } // wrong
|
||||
[](unsigned char c){ return std::tolower(c); } // correct
|
||||
);
|
||||
return s;
|
||||
}
|
||||
|
||||
void Log::SetLogLevel (const std::string& level_) {
|
||||
std::string level=str_tolower(level_);
|
||||
void Log::SetLogLevel (const std::string& level_) {
|
||||
std::string level=str_tolower(level_);
|
||||
if (level == "none") { m_MinLevel = eLogNone; }
|
||||
else if (level == "error") { m_MinLevel = eLogError; }
|
||||
else if (level == "warn") { m_MinLevel = eLogWarning; }
|
||||
|
@ -240,7 +240,7 @@ namespace log {
|
|||
static ThrowFunction g_ThrowFunction;
|
||||
ThrowFunction GetThrowFunction () { return g_ThrowFunction; }
|
||||
void SetThrowFunction (ThrowFunction f) { g_ThrowFunction = f; }
|
||||
|
||||
|
||||
} // log
|
||||
} // i2p
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue