mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-15 16:39:14 +00:00
part2
This commit is contained in:
parent
23d5fc1900
commit
d40bb06400
13
src/switch.c
13
src/switch.c
@ -82,6 +82,7 @@ static void handle_SIGILL(int sig)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef WIN32
|
||||||
static void handle_SIGUSR2(int sig)
|
static void handle_SIGUSR2(int sig)
|
||||||
{
|
{
|
||||||
if (sig);
|
if (sig);
|
||||||
@ -106,6 +107,7 @@ static void handle_SIGCHLD(int sig)
|
|||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* kill a freeswitch process running in background mode */
|
/* kill a freeswitch process running in background mode */
|
||||||
static int freeswitch_kill_background()
|
static int freeswitch_kill_background()
|
||||||
@ -272,7 +274,16 @@ void daemonize(int do_wait)
|
|||||||
|
|
||||||
|
|
||||||
if (do_wait) {
|
if (do_wait) {
|
||||||
unsigned int sanity = 20;
|
unsigned int sanity = 60;
|
||||||
|
char *o;
|
||||||
|
|
||||||
|
if ((o = getenv("FREESWITCH_BG_TIMEOUT"))) {
|
||||||
|
int tmp = atoi(o);
|
||||||
|
if (tmp > 0) {
|
||||||
|
sanity = tmp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
while(--sanity && !system_ready) {
|
while(--sanity && !system_ready) {
|
||||||
|
|
||||||
if (sanity % 2 == 0) {
|
if (sanity % 2 == 0) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user