Lines 279-284
int main(int argc, char **argv)
Link Here
|
279 |
int stdout_fd; |
279 |
int stdout_fd; |
280 |
int stderr_fd; |
280 |
int stderr_fd; |
281 |
pid_t pid, spid; |
281 |
pid_t pid, spid; |
|
|
282 |
rc_pidlist *pids; |
282 |
int i; |
283 |
int i; |
283 |
char *svcname = getenv("RC_SVCNAME"); |
284 |
char *svcname = getenv("RC_SVCNAME"); |
284 |
RC_STRINGLIST *env_list; |
285 |
RC_STRINGLIST *env_list; |
Lines 683-691
int main(int argc, char **argv)
Link Here
|
683 |
else |
684 |
else |
684 |
pid = 0; |
685 |
pid = 0; |
685 |
|
686 |
|
686 |
if (do_stop(applet, exec, (const char * const *)margv, pid, uid, |
687 |
if (pid) |
687 |
0, test, false) > 0) |
688 |
pids = rc_find_pids(NULL, NULL, 0, pid); |
|
|
689 |
else |
690 |
pids = rc_find_pids(exec, argv, uid, 0); |
691 |
|
692 |
if (TAILQ_LENGTH(pids)) |
688 |
eerrorx("%s: %s is already running", applet, exec); |
693 |
eerrorx("%s: %s is already running", applet, exec); |
|
|
694 |
free(pids); |
689 |
|
695 |
|
690 |
if (test) { |
696 |
if (test) { |
691 |
if (rc_yesno(getenv("EINFO_QUIET"))) |
697 |
if (rc_yesno(getenv("EINFO_QUIET"))) |