mirror of
https://github.com/troglobit/finit.git
synced 2026-10-29 12:40:44 +00:00
Fix #185: add devmon support, <dev/foo> condition provider
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This commit is contained in:
1 parent
c586204fc1
commit
17c69fef3d
7 files changed
+328
-6
No files matched your search
@@ -43,6 +43,7 @@
|
||||
#include "client.h"
|
||||
#include "conf.h"
|
||||
#include "cond.h"
|
||||
#include "devmon.h"
|
||||
#include "finit.h"
|
||||
#include "helpers.h"
|
||||
#include "pid.h"
|
||||
@@ -1696,10 +1697,16 @@ int service_register(int type, char *cfg, struct rlimit rlimit[], char *file)
|
||||
*/
|
||||
void service_unregister(svc_t *svc)
|
||||
{
|
||||
char *c;
|
||||
|
||||
if (!svc)
|
||||
return;
|
||||
|
||||
service_stop(svc);
|
||||
|
||||
for (c = strtok(svc->cond, ","); c; c = strtok(NULL, ","))
|
||||
devmon_del_cond(c);
|
||||
|
||||
svc_del(svc);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user