[gnome-continuous-yocto/gnomeostree-3.28-rocko: 2926/8267] update-rc.d.bbclass: check that init script is executable before running it



commit ac647ea6964e166c395334fe107015030adc1b76
Author: Markus Lehtonen <markus lehtonen linux intel com>
Date:   Thu Oct 6 16:37:04 2016 +0300

    update-rc.d.bbclass: check that init script is executable before running it
    
    Check that the init script that is going to be called in the prerm()
    script really exists and is executable. There might be a packaging bug
    or the script might've been removed already earlier in prerm().
    
    [YOCTO #10299]
    
    (From OE-Core rev: aabb87c9dbd60fe9467ca0354ec05c275a3f1b1a)
    
    Signed-off-by: Markus Lehtonen <markus lehtonen linux intel com>
    Signed-off-by: Richard Purdie <richard purdie linuxfoundation org>

 meta/classes/update-rc.d.bbclass |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/meta/classes/update-rc.d.bbclass b/meta/classes/update-rc.d.bbclass
index dfef2a2..348f3c0 100644
--- a/meta/classes/update-rc.d.bbclass
+++ b/meta/classes/update-rc.d.bbclass
@@ -37,7 +37,7 @@ fi
 }
 
 updatercd_prerm() {
-if [ -z "$D" ]; then
+if [ -z "$D" -a -x "${INIT_D_DIR}/${INITSCRIPT_NAME}" ]; then
        ${INIT_D_DIR}/${INITSCRIPT_NAME} stop
 fi
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]