]> code.ossystems Code Review - openembedded-core.git/commitdiff
update-rc.d.bbclass: Stop the class corrupting the D variable
authorRichard Purdie <richard@openedhand.com>
Mon, 6 Aug 2007 07:33:58 +0000 (07:33 +0000)
committerRichard Purdie <richard@openedhand.com>
Mon, 6 Aug 2007 07:33:58 +0000 (07:33 +0000)
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@2369 311d38ba-8fff-0310-9ca6-ca027cbcb966

meta/classes/update-rc.d.bbclass

index 9821eec5b23e00b3e47cbb2319f0d7a4a819ddfe..cb217681e3897ea8d73031c0e64fd8eb0462eede 100644 (file)
@@ -7,17 +7,15 @@ INIT_D_DIR = "${sysconfdir}/init.d"
 
 updatercd_postinst() {
 if test "x$D" != "x"; then
-       D="-r $D"
+       OPT="-r $D"
 else
-       D="-s"
+       OPT="-s"
 fi
-update-rc.d $D ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS}
+update-rc.d $OPT ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS}
 }
 
 updatercd_prerm() {
-if test "x$D" != "x"; then
-       D="-r $D"
-else
+if test "x$D" == "x"; then
        ${INIT_D_DIR}/${INITSCRIPT_NAME} stop
 fi
 }