IBR-DTN  1.0.0
Main.cpp File Reference
#include "config.h"
#include "Configuration.h"
#include <ibrcommon/Logger.h>
#include <ibrcommon/data/File.h>
#include <ibrcommon/thread/SignalHandler.h>
#include <libdaemon/daemon.h>
#include <string.h>
#include <set>
#include <sys/types.h>
#include <unistd.h>
#include <syslog.h>
#include <pwd.h>
#include "NativeDaemon.h"
Include dependency graph for Main.cpp:

Go to the source code of this file.

Functions

void func_sighandler (int signal)
 
int __daemon_run ()
 
int main (int argc, char *argv[])
 

Variables

dtn::daemon::NativeDaemon _dtnd
 
unsigned char logopts = ibrcommon::Logger::LOG_DATETIME | ibrcommon::Logger::LOG_LEVEL | ibrcommon::Logger::LOG_TAG
 
const unsigned char logerr = ibrcommon::Logger::LOGGER_ERR | ibrcommon::Logger::LOGGER_CRIT
 
const unsigned char logstd = ibrcommon::Logger::LOGGER_ALL ^ (ibrcommon::Logger::LOGGER_DEBUG | ibrcommon::Logger::LOGGER_NOTICE | logerr)
 
const unsigned char logsys = ibrcommon::Logger::LOGGER_ALL ^ (ibrcommon::Logger::LOGGER_DEBUG | ibrcommon::Logger::LOGGER_NOTICE)
 
bool _debug = false
 
ibrcommon::Conditional _shutdown_cond
 
bool _shutdown = false
 

Function Documentation

void func_sighandler ( int  signal)

Definition at line 74 of file Main.cpp.

References _debug, _shutdown, _shutdown_cond, logopts, dtn::daemon::NativeDaemon::reload(), and dtn::daemon::NativeDaemon::setDebug().

Referenced by __daemon_run().

Here is the call graph for this function:

Variable Documentation

bool _debug = false

Definition at line 48 of file Main.cpp.

ibrcommon::Conditional _shutdown_cond

Definition at line 70 of file Main.cpp.

Referenced by __daemon_run(), and func_sighandler().

const unsigned char logerr = ibrcommon::Logger::LOGGER_ERR | ibrcommon::Logger::LOGGER_CRIT

Definition at line 58 of file Main.cpp.

Referenced by __daemon_run(), init_logger(), and main().

unsigned char logopts = ibrcommon::Logger::LOG_DATETIME | ibrcommon::Logger::LOG_LEVEL | ibrcommon::Logger::LOG_TAG

setup logging capabilities

Definition at line 55 of file Main.cpp.

Referenced by __daemon_run(), func_sighandler(), init_logger(), main(), and dtn::daemon::NativeDaemon::setLogFile().

const unsigned char logstd = ibrcommon::Logger::LOGGER_ALL ^ (ibrcommon::Logger::LOGGER_DEBUG | ibrcommon::Logger::LOGGER_NOTICE | logerr)

Definition at line 61 of file Main.cpp.

Referenced by __daemon_run(), init_logger(), and main().

const unsigned char logsys = ibrcommon::Logger::LOGGER_ALL ^ (ibrcommon::Logger::LOGGER_DEBUG | ibrcommon::Logger::LOGGER_NOTICE)