mirror of
https://github.com/troglobit/finit.git
synced 2026-11-09 16:21:24 +00:00
Rename stat_restart_counter --> restart_counter
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
740d447442
commit
f97aab4699
2 files changed
+4
-4
No files matched your search
@@ -383,7 +383,7 @@ void svc_monitor(void)
|
|||||||
|
|
||||||
/* Restarting lost service. */
|
/* Restarting lost service. */
|
||||||
if (svc_enabled(svc, 0, NULL)) {
|
if (svc_enabled(svc, 0, NULL)) {
|
||||||
svc->stat_restart_counter++;
|
svc->restart_counter++;
|
||||||
svc_start(svc);
|
svc_start(svc);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -509,7 +509,7 @@ int svc_stop(svc_t *svc)
|
|||||||
if (svc->pid <= 1) {
|
if (svc->pid <= 1) {
|
||||||
_d("Bad PID %d for %s, SIGTERM", svc->pid, svc->desc);
|
_d("Bad PID %d for %s, SIGTERM", svc->pid, svc->desc);
|
||||||
svc->pid = 0;
|
svc->pid = 0;
|
||||||
svc->stat_restart_counter = 0;
|
svc->restart_counter = 0;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -523,7 +523,7 @@ int svc_stop(svc_t *svc)
|
|||||||
if (runlevel != 1)
|
if (runlevel != 1)
|
||||||
print_result(res);
|
print_result(res);
|
||||||
svc->pid = 0;
|
svc->pid = 0;
|
||||||
svc->stat_restart_counter = 0;
|
svc->restart_counter = 0;
|
||||||
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -59,7 +59,7 @@ typedef struct svc {
|
|||||||
svc_type_t type;
|
svc_type_t type;
|
||||||
int reload;
|
int reload;
|
||||||
int runlevels;
|
int runlevels;
|
||||||
unsigned int stat_restart_counter; /* Incremented for each restart by service monitor. */
|
unsigned int restart_counter; /* Incremented for each restart by service monitor. */
|
||||||
char cmd[MAX_ARG_LEN];
|
char cmd[MAX_ARG_LEN];
|
||||||
char args[MAX_NUM_SVC_ARGS][MAX_ARG_LEN];
|
char args[MAX_NUM_SVC_ARGS][MAX_ARG_LEN];
|
||||||
char desc[MAX_STR_LEN];
|
char desc[MAX_STR_LEN];
|
||||||
|
|||||||
Reference in new issue
Block a user