/*
** SellaNMS
** $Id: main.h,v 2.19 2006/01/24 07:08:09 sella Exp $
** Copyright (c) 2001-2005 Digital Genesis Software, LLC. All Rights Reserved.
** Released under the GPL Version 2 License.
** http://www.digitalgenesis.com
*/

#ifndef __DGS_MAIN_H
#define __DGS_MAIN_H

#ifdef HAVE_CONFIG_H
	#include "config.h"
#endif

#include "defaults.h"
#include "configuration/configuration.h"
#include <stl/slist>
#include <stl/string>
#include <stl/vector>

#define MAIN_SYSLOG_FACILITY_DEF	LOG_LOCAL0
#define MAIN_INTERRUPT_WAIT		1 /* 1 sec between accepting interrupts */

void sighandler(int sig);
int main(int argc, char** argv);
RESULT version(void);
RESULT about(void);
RESULT usage();
RESULT checkEuidRoot();
RESULT processCommandLine(int argc, char **argv);
RESULT processDaemonOptions();
RESULT processTraceOptions();
RESULT processDebug();
RESULT writePidFile(const char* pid_file, pid_t pid);
RESULT readConfig();
void loadMibs();
void unloadMibs();
RESULT grantPriv();
RESULT dropPriv();
char* getConfigPath();

#endif

/*
** Local Variables:
** c-basic-offset: 3
** tab-width: 3
** End:
** vim:
** vim: noet ts=3 sw=3
*/
