With current forking model of minidlna, we no longer need the event module in the child, so shut it down. While here, make any error from fork() a fatal error.
This commit is contained in:
parent
33fb664fba
commit
aefe4dd0bf
@ -38,9 +38,10 @@
|
||||
#include <signal.h>
|
||||
#include <sys/wait.h>
|
||||
|
||||
#include "config.h"
|
||||
#include "event.h"
|
||||
#include "upnpglobalvars.h"
|
||||
#include "process.h"
|
||||
#include "config.h"
|
||||
#include "log.h"
|
||||
|
||||
struct child *children = NULL;
|
||||
@ -100,7 +101,10 @@ process_fork(struct client_cache_s *client)
|
||||
client->connections++;
|
||||
add_process_info(pid, client);
|
||||
number_of_children++;
|
||||
}
|
||||
} else if (pid == 0)
|
||||
event_module.fini();
|
||||
else
|
||||
DPRINTF(E_FATAL, L_GENERAL, "Fork() failed: %s\n", strerror(errno));
|
||||
|
||||
return pid;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user