fix build on osx (#695)

This commit is contained in:
redPanther 2016-06-12 22:27:34 +02:00 committed by brindosch
parent 7dfb9f1967
commit 9f564f8d89
1 changed files with 4 additions and 0 deletions

View File

@ -46,7 +46,11 @@ Logger::Logger ( std::string name, LogLevel minLevel ):
_syslogEnabled(true),
_loggerId(loggerId++)
{
#ifdef GLIBC
_appname = std::string(program_invocation_short_name);
#else
_appname = std::string(getprogname());
#endif
std::transform(_appname.begin(), _appname.end(),_appname.begin(), ::toupper);
loggerCount++;