Ignore:
Timestamp:
01/03/2008 22:54:56 (4 years ago)
Author:
chris
Message:

Add support for logging just to syslog (not console) at a given
priority.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • box/trunk/lib/common/Logging.h

    r2092 r2102  
    3131        line << stuff; \ 
    3232        Logging::Log(level, __FILE__, __LINE__, line.str()); \ 
     33} 
     34 
     35#define BOX_SYSLOG(level, stuff) \ 
     36{ \ 
     37        std::ostringstream line; \ 
     38        line << stuff; \ 
     39        Logging::LogToSyslog(level, __FILE__, __LINE__, line.str()); \ 
    3340} 
    3441 
     
    197204        static void Log(Log::Level level, const std::string& rFile,  
    198205                int line, const std::string& rMessage); 
     206        static void LogToSyslog(Log::Level level, const std::string& rFile,  
     207                int line, const std::string& rMessage); 
    199208        static void SetContext(std::string context); 
    200209        static void ClearContext(); 
Note: See TracChangeset for help on using the changeset viewer.