diff options
author | William Hubbs <w.d.hubbs@gmail.com> | 2015-04-26 13:31:49 -0500 |
---|---|---|
committer | William Hubbs <w.d.hubbs@gmail.com> | 2015-04-27 11:21:29 -0500 |
commit | 8b9349208696e5caed1a8b34f066cec4ee642194 (patch) | |
tree | 0ee1fce0de32aecfcd5c314322067879fc0e73cd /src/librc | |
parent | 4b1b457cd15cc1609c101b99a49a5e4c67b62567 (diff) |
convert all references from runscript to openrc-run
Diffstat (limited to 'src/librc')
-rw-r--r-- | src/librc/librc-daemon.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/librc/librc-daemon.c b/src/librc/librc-daemon.c index 3811a043..4986f70d 100644 --- a/src/librc/librc-daemon.c +++ b/src/librc/librc-daemon.c @@ -99,7 +99,7 @@ rc_find_pids(const char *exec, const char *const *argv, uid_t uid, pid_t pid) pid_t p; char buffer[PATH_MAX]; struct stat sb; - pid_t runscript_pid = 0; + pid_t openrc_pid = 0; char *pp; RC_PIDLIST *pids = NULL; RC_PID *pi; @@ -108,7 +108,7 @@ rc_find_pids(const char *exec, const char *const *argv, uid_t uid, pid_t pid) return NULL; /* - We never match RC_RUNSCRIPT_PID if present so we avoid the below + We never match RC_OPENRC_PID if present so we avoid the below scenario /etc/init.d/ntpd stop does @@ -118,9 +118,9 @@ rc_find_pids(const char *exec, const char *const *argv, uid_t uid, pid_t pid) nasty */ - if ((pp = getenv("RC_RUNSCRIPT_PID"))) { - if (sscanf(pp, "%d", &runscript_pid) != 1) - runscript_pid = 0; + if ((pp = getenv("RC_OPENRC_PID"))) { + if (sscanf(pp, "%d", &openrc_pid) != 1) + openrc_pid = 0; } /* @@ -146,7 +146,7 @@ rc_find_pids(const char *exec, const char *const *argv, uid_t uid, pid_t pid) while ((entry = readdir(procdir)) != NULL) { if (sscanf(entry->d_name, "%d", &p) != 1) continue; - if (runscript_pid != 0 && runscript_pid == p) + if (openrc_pid != 0 && openrc_pid == p) continue; if (pid != 0 && pid != p) continue; |