Do not start the daemon more than once
Avoid starting multiple daemon instances if the --daemon argument is passed and the daemon is already running. Terminate the already running instance before spawning a new one instead. Suggested-by: Vlad Glagolev <scm@vaygr.net> Signed-off-by: Lukas Fleischer <lfleischer@calcurse.org>
This commit is contained in:
@@ -803,6 +803,7 @@ int parse_args(int argc, char **argv)
|
||||
io_export_data(xfmt, export_uid);
|
||||
} else if (daemon) {
|
||||
notify_init_vars();
|
||||
dmon_stop();
|
||||
dmon_start(0);
|
||||
} else {
|
||||
/* interactive mode */
|
||||
|
||||
Reference in New Issue
Block a user