[LEDE-DEV] [PATCH 3/3] base-files: protect stop and reload actions with procd_lock
Roman Yeryomin
roman at advem.lv
Thu Dec 14 13:55:08 PST 2017
Signed-off-by: Roman Yeryomin <roman at advem.lv>
Signed-off-by: Andrejs Hanins <ahanins at gmail.com>
---
package/base-files/files/etc/rc.common | 2 ++
1 file changed, 2 insertions(+)
diff --git a/package/base-files/files/etc/rc.common b/package/base-files/files/etc/rc.common
index a2ea6a5679..89ad187c3c 100755
--- a/package/base-files/files/etc/rc.common
+++ b/package/base-files/files/etc/rc.common
@@ -126,12 +126,14 @@ ${INIT_TRACE:+set -x}
}
stop() {
+ procd_lock
stop_service "$@"
procd_kill "$(basename ${basescript:-$initscript})" "$1"
}
reload() {
if eval "type reload_service" 2>/dev/null >/dev/null; then
+ procd_lock
reload_service "$@"
else
start
--
2.14.1
More information about the Lede-dev
mailing list