diff options
author | Martin Willi <martin@strongswan.org> | 2006-04-20 07:06:39 +0000 |
---|---|---|
committer | Martin Willi <martin@strongswan.org> | 2006-04-20 07:06:39 +0000 |
commit | 8bc96e08cb0c613edc35bcc6c3e8028b4db9e0aa (patch) | |
tree | 01f156479d22c765f0d99df0a5c4a07bcfe2c3f5 /Source/charon/daemon.c | |
parent | ec6582ccaa59e38cb83650c7c6b8312dc9768e87 (diff) | |
download | strongswan-8bc96e08cb0c613edc35bcc6c3e8028b4db9e0aa.tar.bz2 strongswan-8bc96e08cb0c613edc35bcc6c3e8028b4db9e0aa.tar.xz |
- fixed log-to-syslog behavior
- added patch against strongswan-2.6.4
Diffstat (limited to 'Source/charon/daemon.c')
-rw-r--r-- | Source/charon/daemon.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Source/charon/daemon.c b/Source/charon/daemon.c index d7265531d..376a09979 100644 --- a/Source/charon/daemon.c +++ b/Source/charon/daemon.c @@ -27,6 +27,7 @@ #include <sys/types.h> #include <unistd.h> #include <execinfo.h> +#include <string.h> #include "daemon.h" @@ -332,6 +333,16 @@ int main(int argc, char *argv[]) private_daemon_t *private_charon; FILE *pid_file; struct stat stb; + int i; + + /* trivial argument parsing */ + for (i = 1; i < argc; i++) + { + if (strcmp(argv[i], "--use-syslog") == 0) + { + logger_manager->set_output(logger_manager, ALL_LOGGERS, NULL); + } + } private_charon = daemon_create(); charon = (daemon_t*)private_charon; |