#include <unistd.h>
#include <getopt.h>
#include <cstdarg>
#include <sstream>
#include <list>
#include <set>
#include <map>
#include <fstream>
#include "cst/constants.hh"
#include "net/ipaddress.hh"
#include "set/interfaces.hh"
#include "sys/interfaceinfo.hh"
#include "set/gate.hh"
#include "utl/log.hh"
#include "utl/syslog.hh"
Go to the source code of this file.
Namespaces | |
namespace | olsr |
namespace | olsr::utl |
namespace | olsr::utl::internal |
namespace | std |
Defines | |
#define | QOLYESTER_DAEMON_UTL_ARGS_HXX 1 |
#define | ARG_VERSION 256 |
#define | ARG_DUMPSTATE 257 |
#define | ARG_DUMPHELLO 258 |
#define | ARG_DUMPTC 259 |
#define | ARG_DUMPMID 260 |
#define | ARG_DUMPHNA 261 |
#define | ARG_DUMPALL 262 |
#define | ARG_ERRORFILE 263 |
#define | ARG_WARNINGFILE 264 |
#define | ARG_NOTICEFILE 265 |
#define | ARG_DUMPFILE 266 |
#define | ARG_DEBUGFILE 267 |
#define | ARG_DUMPPROF 268 |
#define | ARG_NOTABLES 270 |
#define | ARG_SWSOCK 271 |
#define | ARG_ALLFILE 272 |
#define | ARG_DEBUGTRACE 273 |
#define | ARG_HELLOINTERVAL 274 |
#define | ARG_REFRESHINTERVAL 275 |
#define | ARG_TCINTERVAL 276 |
#define | ARG_MIDINTERVAL 277 |
#define | ARG_HNAINTERVAL 278 |
#define | ARG_MIDHOLDTIME 279 |
#define | ARG_HNAHOLDTIME 280 |
#define | ARG_NEIGHBHOLDTIME 281 |
#define | ARG_TOPHOLDTIME 282 |
#define | ARG_DUPHOLDTIME 283 |
#define | ARG_MAXJITTERTIME 284 |
#define | ARG_DUMPINTERVAL 287 |
#define | ARG_DIRTYPROMISCHACK 288 |
#define | GETNUMBER(Variable, Option) |
#define | PROC_BUF(Name, Buf) |
#define | SPB StringPrefixBuf |
#define | PROC_LOG_PREFIXED(Name) |
#define | PROC_LOG(Name) |
#define | SPB StringPrefixBuf |
#define | PROC_LOG_PREFIXED(Name, Level) |
#define | PROC_LOG(Name, Level) |
Variables | |
std::ostream | dump |
std::ostream | dump_prof |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Value: do { \ char* p; \ unsigned val = strtoul(optarg, &p, 10); \ if (p == optarg || *p != 0 || val == 0) \ die("Parse error in --" Option ": %s\n", optarg); \ cst:: Variable = val; \ } while (0) |
|
Value: do { \ bufmap_t::iterator x = buf_map.find( Name ## _file); \ if (x == buf_map.end()) { \ std::filebuf* b = new std::filebuf; \ b->open( Name ## _file.c_str(), \ std::ios_base::out | std::ios_base::app); \ if (!b->is_open()) \ die("Could not open \"%s\" for writing: %s\n", \ Name ## _file.c_str(), strerror(errno)); \ x = buf_map.insert(bufmap_t:: \ value_type( Name ## _file, b)).first; \ } \ Buf ->set_streambuf(x->second); \ } while (false) |
|
Value: do { \ if ( Name ## _file.empty()) { \ std::streambuf* b; \ \ if(debugtrace) { \ assert(dynamic_cast<YBuf*>( Name .rdbuf()) != 0); \ YBuf* yb = static_cast<YBuf*>( Name .rdbuf()); \ b = yb->get_streambuf1(); \ } else \ b = Name .rdbuf(); \ \ assert(dynamic_cast<LevelBuf*>(b) != 0); \ LevelBuf* lb = static_cast<LevelBuf*>(b); \ \ if (timestamps) { \ assert(dynamic_cast<TimestampBuf*>(lb->get_streambuf()) != 0); \ delete static_cast<TimestampBuf*>(lb->get_streambuf()); \ } \ \ lb->set_streambuf(new utl::SyslogBuf( Level )); \ } \ } while (false) |
|
Value: do { \ if (! Name ## _file.empty()) { \ assert(dynamic_cast<LevelBuf*>( Name .rdbuf()) != 0); \ LevelBuf* b = static_cast<LevelBuf*>( Name .rdbuf()); \ if (timestamps) { \ TimestampBuf* tb = \ new TimestampBuf(b->get_streambuf()); \ PROC_BUF( Name , tb); \ b->set_streambuf(tb); \ } else \ PROC_BUF( Name , b); \ } else if (timestamps) { \ assert(dynamic_cast<LevelBuf*>( Name .rdbuf()) != 0); \ LevelBuf* b = static_cast<LevelBuf*>( Name .rdbuf()); \ TimestampBuf* tb = new TimestampBuf(b->get_streambuf()); \ b->set_streambuf(tb); \ } \ } while (false) |
|
Value: do { \ if ( Name ## _file.empty()) { \ std::streambuf* b; \ \ if(debugtrace) { \ assert(dynamic_cast<YBuf*>( Name .rdbuf()) != 0); \ YBuf* yb = static_cast<YBuf*>( Name .rdbuf()); \ b = yb->get_streambuf1(); \ } else \ b = Name .rdbuf(); \ \ assert(dynamic_cast<LevelBuf*>(b) != 0); \ LevelBuf* lb = static_cast<LevelBuf*>(b); \ assert(dynamic_cast< SPB *>(lb->get_streambuf()) != 0); \ SPB * sb = static_cast<SPB *>(lb->get_streambuf()); \ \ if (timestamps) { \ assert(dynamic_cast<TimestampBuf*>(sb->get_streambuf()) != 0); \ delete static_cast<TimestampBuf*>(sb->get_streambuf()); \ } \ \ sb->set_streambuf(new utl::SyslogBuf( Level )); \ } \ } while (false) |
|
Value: do { \ if (! Name ## _file.empty()) { \ assert(dynamic_cast<LevelBuf*>( Name .rdbuf()) != 0); \ LevelBuf* b = static_cast<LevelBuf*>( Name .rdbuf()); \ assert(dynamic_cast< SPB *>(b->get_streambuf()) != 0); \ SPB * sb = static_cast< SPB *>(b->get_streambuf()); \ if (timestamps) { \ TimestampBuf* tb = \ new TimestampBuf(sb->get_streambuf()); \ PROC_BUF( Name , tb); \ sb->set_streambuf(tb); \ } else \ PROC_BUF( Name , sb); \ } else if (timestamps) { \ assert(dynamic_cast<LevelBuf*>( Name .rdbuf()) != 0); \ LevelBuf* b = static_cast<LevelBuf*>( Name .rdbuf()); \ assert(dynamic_cast< SPB *>(b->get_streambuf()) != 0); \ SPB * sb = static_cast< SPB *>(b->get_streambuf()); \ TimestampBuf* tb = new TimestampBuf(sb->get_streambuf()); \ sb->set_streambuf(tb); \ } \ } while (false) |
|
|
|
|
|
|
|
|
|
|