head 1.7; access; symbols OPENPKG_E1_MP_HEAD:1.2 OPENPKG_E1_MP:1.2 OPENPKG_E1_MP_2_STABLE:1.2.2.2 OPENPKG_E1_FP:1.2.2.2 OPENPKG_2_STABLE_MP:1.2 OPENPKG_2_STABLE_20061018:1.2.2.2 OPENPKG_2_STABLE:1.2.0.2; locks; strict; comment @# @; 1.7 date 2009.10.12.07.07.04; author rse; state Exp; branches; next 1.6; commitid zTEfJg3LOMWEld7u; 1.6 date 2008.07.24.17.32.59; author rse; state Exp; branches; next 1.5; commitid 3Y0ZSctlfI5e75ct; 1.5 date 2008.01.20.08.04.00; author rse; state Exp; branches; next 1.4; commitid WT0sAgG0c6sHW7Os; 1.4 date 2008.01.19.20.08.08; author rse; state Exp; branches; next 1.3; commitid 24gB1rGqjvH8Z3Os; 1.3 date 2007.10.29.08.22.28; author rse; state Exp; branches; next 1.2; commitid ckL7ZEnTekJsIsDs; 1.2 date 2006.09.01.15.40.15; author rse; state Exp; branches 1.2.2.1; next 1.1; commitid rH8633NwM9aEJ8Lr; 1.1 date 2006.08.31.08.30.18; author rse; state Exp; branches; next ; commitid yYf4LfyiDFA8oYKr; 1.2.2.1 date 2006.09.01.15.40.15; author rse; state dead; branches; next 1.2.2.2; commitid iZxwRSmmWscPXUQr; 1.2.2.2 date 2006.10.16.14.56.24; author rse; state Exp; branches; next ; commitid iZxwRSmmWscPXUQr; desc @@ 1.7 log @upgrading package: siproxd 0.7.1 -> 0.7.2 @ text @Index: src/plugin_shortdial.c --- src/plugin_shortdial.c.orig 2009-03-24 18:38:42 +0100 +++ src/plugin_shortdial.c 2009-10-12 09:03:16 +0200 @@@@ -26,6 +26,7 @@@@ #include #include #include +#include #include #include Index: src/proxy.c --- src/proxy.c.orig 2009-07-30 19:20:55 +0200 +++ src/proxy.c 2009-10-12 09:02:53 +0200 @@@@ -1084,6 +1084,7 @@@@ memcpy(&addr_media, &addr_sess, sizeof(addr_sess)); } +#if 0 /* * Am I running in front of the routing device? Then I cannot * use the external IP to bind a listen socket to, but should @@@@ -1103,6 +1104,7 @@@@ memcpy(&map_addr, &inside_addr, sizeof (map_addr)); } } +#endif sts = rtp_start_fwd(osip_message_get_call_id(mymsg), client_id, Index: src/siproxd.c --- src/siproxd.c.orig 2009-01-07 21:37:11 +0100 +++ src/siproxd.c 2009-10-12 09:02:53 +0200 @@@@ -29,6 +29,7 @@@@ #include #include #include +#include #ifdef HAVE_GETOPT_H #include @@@@ -145,6 +146,7 @@@@ log_init(); + openlog("siproxd", LOG_NDELAY, LOG_DAEMON); log_set_stderr(1); /* @@@@ -233,6 +235,9 @@@@ if (read_config(configfile, config_search, main_cfg_opts, "") == STS_FAILURE) { exit(1); } + /* Don't log to stderr if daemonizing is intended. */ + if (configuration.daemonize) + log_set_stderr(0); /* remember where config file is located, so the plugins * can load it as well - if required */ configuration.configfile = strdup(configfile); Index: src/utils.c --- src/utils.c.orig 2009-07-30 19:02:28 +0200 +++ src/utils.c 2009-10-12 09:02:53 +0200 @@@@ -43,6 +43,11 @@@@ #include +#ifndef MAXINT +#include +#define MAXINT INT_MAX +#endif + #include "siproxd.h" #include "log.h" @ 1.6 log @upgrading package: siproxd 0.7.0 -> 0.7.1 @ text @d2 3 a4 3 --- src/plugin_shortdial.c.orig 2008-02-02 18:13:31 +0100 +++ src/plugin_shortdial.c 2008-07-24 08:44:56 +0200 @@@@ -23,6 +23,7 @@@@ d9 2 a11 2 #include d13 3 a15 3 --- src/proxy.c.orig 2008-02-24 19:29:38 +0100 +++ src/proxy.c 2008-07-24 08:44:56 +0200 @@@@ -1048,6 +1048,7 @@@@ d23 1 a23 1 @@@@ -1067,6 +1068,7 @@@@ d32 2 a33 2 --- src/siproxd.c.orig 2008-02-04 21:38:47 +0100 +++ src/siproxd.c 2008-07-24 08:46:29 +0200 d42 1 a42 1 @@@@ -144,6 +145,7 @@@@ d50 1 a50 1 @@@@ -232,6 +234,9 @@@@ d61 2 a62 2 --- src/utils.c.orig 2008-01-19 17:07:14 +0100 +++ src/utils.c 2008-07-24 08:44:56 +0200 @ 1.5 log @upgrading package: siproxd 0.6.1 -> 0.7.0 @ text @d2 2 a3 2 --- src/plugin_shortdial.c.orig 2008-01-19 17:07:14 +0100 +++ src/plugin_shortdial.c 2008-01-20 08:54:32 +0100 d10 1 a11 1 #include d13 3 a15 3 --- src/proxy.c.orig 2008-01-19 17:07:14 +0100 +++ src/proxy.c 2008-01-20 08:54:32 +0100 @@@@ -1076,6 +1076,7 @@@@ d23 1 a23 1 @@@@ -1095,6 +1096,7 @@@@ d32 2 a33 2 --- src/siproxd.c.orig 2008-01-19 17:07:14 +0100 +++ src/siproxd.c 2008-01-20 08:54:32 +0100 d42 1 a42 1 @@@@ -100,6 +101,7 @@@@ d50 4 a53 9 @@@@ -182,11 +184,16 @@@@ /* * Init stuff */ - INFO(PACKAGE"-"VERSION"-"BUILDSTR" "UNAME" starting up"); - /* read the config file */ if (read_config(configfile, config_search) == STS_FAILURE) exit(1); d55 1 a55 1 + if (configuration.daemonize) { d57 3 a59 7 + } + + INFO(PACKAGE"-"VERSION"-"BUILDSTR" "UNAME" starting up"); + /* if a debug level > 0 has been given on the commandline use its value and not what is in the config file */ if (cmdline_debuglevel != 0) { d62 1 a62 1 +++ src/utils.c 2008-01-20 08:55:57 +0100 @ 1.4 log @upgrading package: siproxd 0.6.0 -> 0.6.1 @ text @d2 3 a4 4 --- src/plugin_shortdial.c.orig 2007-06-08 21:43:20 +0200 +++ src/plugin_shortdial.c 2008-01-19 21:05:10 +0100 @@@@ -22,6 +22,7 @@@@ d6 1 d13 2 a14 2 --- src/proxy.c.orig 2007-11-22 20:12:47 +0100 +++ src/proxy.c 2008-01-19 21:05:10 +0100 d32 2 a33 2 --- src/siproxd.c.orig 2007-11-28 21:51:45 +0100 +++ src/siproxd.c 2008-01-19 21:05:10 +0100 d70 5 a74 5 --- src/utils.c.orig 2007-12-20 18:42:10 +0100 +++ src/utils.c 2008-01-19 21:06:40 +0100 @@@@ -46,6 +46,11 @@@@ #include "siproxd.h" #include "log.h" d81 2 a82 1 static char const ident[]="$Id: utils.c,v 1.52 2007/12/20 17:42:10 hb9xar Exp $"; a83 1 /* configuration storage */ @ 1.3 log @upgrading package: siproxd 0.5.13 -> 0.6.0 @ text @d3 1 a3 1 +++ src/plugin_shortdial.c 2007-10-29 09:19:48 +0100 d13 2 a14 2 --- src/proxy.c.orig 2007-10-28 14:48:10 +0100 +++ src/proxy.c 2007-10-29 09:19:48 +0100 d22 4 a25 4 * use the external IP to bind a listen socket to, so force @@@@ -1088,6 +1089,7 @@@@ "in-front-of-NAT-Router"); memcpy(&map_addr, &inside_addr, sizeof (map_addr)); d32 3 a34 3 --- src/siproxd.c.orig 2007-06-08 21:42:10 +0200 +++ src/siproxd.c 2007-10-29 09:19:48 +0100 @@@@ -28,6 +28,7 @@@@ d42 1 a42 1 @@@@ -99,6 +100,7 @@@@ d50 1 a50 1 @@@@ -181,11 +183,16 @@@@ a68 8 @@@@ -214,7 +221,6 @@@@ setsid(); if (fork()!=0) exit(0); - log_set_stderr(0); INFO("daemonized, pid=%i", getpid()); } d70 3 a72 11 --- src/utils.c.orig 2007-09-03 21:55:11 +0200 +++ src/utils.c 2007-10-29 09:20:26 +0100 @@@@ -23,7 +23,6 @@@@ #include #include #include -#include #include #include #include @@@@ -46,6 +45,11 @@@@ d81 1 a81 1 static char const ident[]="$Id: utils.c,v 1.49 2007/09/03 19:55:11 hb9xar Exp $"; @ 1.2 log @fix debug logging; workaround outbound_hostname 'en4' use case conflict @ text @a0 12 Index: src/log.c --- src/log.c.orig 2006-06-18 18:28:43 +0200 +++ src/log.c 2006-08-31 23:06:01 +0200 @@@@ -213,7 +213,7 @@@@ va_list ap, ap_copy; time_t t; struct tm *tim; - char string[128]; + char string[512]; if ((debug_pattern & class) == 0) return; d2 2 a3 2 --- src/plugin_shortdial.c.orig 2006-05-20 13:48:53 +0200 +++ src/plugin_shortdial.c 2006-08-31 22:38:45 +0200 d13 3 a15 3 --- src/proxy.c.orig 2006-06-20 08:34:27 +0200 +++ src/proxy.c 2006-08-31 23:15:39 +0200 @@@@ -1033,6 +1033,7 @@@@ d23 1 a23 1 @@@@ -1045,6 +1046,7 @@@@ d32 2 a33 2 --- src/siproxd.c.orig 2006-06-18 18:28:43 +0200 +++ src/siproxd.c 2006-08-31 22:38:45 +0200 d42 3 a44 3 @@@@ -97,6 +98,7 @@@@ char *pidfilename=NULL; struct sigaction act; d50 1 a50 1 @@@@ -177,11 +179,16 @@@@ d69 1 a69 1 @@@@ -212,7 +219,6 @@@@ d77 23 @ 1.2.2.1 log @file siproxd.patch was added on branch OPENPKG_2_STABLE on 2006-10-16 14:56:24 +0000 @ text @d1 88 @ 1.2.2.2 log @Mass merge from CURRENT to 2-STABLE (all packages except those of JUNK class) @ text @a0 88 Index: src/log.c --- src/log.c.orig 2006-06-18 18:28:43 +0200 +++ src/log.c 2006-08-31 23:06:01 +0200 @@@@ -213,7 +213,7 @@@@ va_list ap, ap_copy; time_t t; struct tm *tim; - char string[128]; + char string[512]; if ((debug_pattern & class) == 0) return; Index: src/plugin_shortdial.c --- src/plugin_shortdial.c.orig 2006-05-20 13:48:53 +0200 +++ src/plugin_shortdial.c 2006-08-31 22:38:45 +0200 @@@@ -22,6 +22,7 @@@@ #include #include +#include #include #include Index: src/proxy.c --- src/proxy.c.orig 2006-06-20 08:34:27 +0200 +++ src/proxy.c 2006-08-31 23:15:39 +0200 @@@@ -1033,6 +1033,7 @@@@ memcpy(&addr_media, &addr_sess, sizeof(addr_sess)); } +#if 0 /* * Am I running in front of the routing device? Then I cannot * use the external IP to bind a listen socket to, so force @@@@ -1045,6 +1046,7 @@@@ "in-front-of-NAT-Router"); memcpy(&map_addr, &inside_addr, sizeof (map_addr)); } +#endif sts = rtp_start_fwd(osip_message_get_call_id(mymsg), client_id, Index: src/siproxd.c --- src/siproxd.c.orig 2006-06-18 18:28:43 +0200 +++ src/siproxd.c 2006-08-31 22:38:45 +0200 @@@@ -28,6 +28,7 @@@@ #include #include #include +#include #ifdef HAVE_GETOPT_H #include @@@@ -97,6 +98,7 @@@@ char *pidfilename=NULL; struct sigaction act; + openlog("siproxd", LOG_NDELAY, LOG_DAEMON); log_set_stderr(1); /* @@@@ -177,11 +179,16 @@@@ /* * Init stuff */ - INFO(PACKAGE"-"VERSION"-"BUILDSTR" "UNAME" starting up"); - /* read the config file */ if (read_config(configfile, config_search) == STS_FAILURE) exit(1); + /* Don't log to stderr if daemonizing is intended. */ + if (configuration.daemonize) { + log_set_stderr(0); + } + + INFO(PACKAGE"-"VERSION"-"BUILDSTR" "UNAME" starting up"); + /* if a debug level > 0 has been given on the commandline use its value and not what is in the config file */ if (cmdline_debuglevel != 0) { @@@@ -212,7 +219,6 @@@@ setsid(); if (fork()!=0) exit(0); - log_set_stderr(0); INFO("daemonized, pid=%i", getpid()); } @ 1.1 log @new package: siproxd 0.5.13 (SIP/RTP Proxy Server) @ text @d1 12 d15 1 a15 1 +++ src/plugin_shortdial.c 2006-08-31 08:25:58 +0200 d24 19 d45 1 a45 1 +++ src/siproxd.c 2006-08-31 08:25:58 +0200 @