[sandbox] init script of sandbox returns an improper return code in status function

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

 



Dear maintainers,

I'm Keigo Noha in Red Hat.
I made a patch for init script in sandbox.

===========================

Author: Keigo Noha <knoha@xxxxxxxxxx>
Date:   Wed Oct 28 17:21:02 2015 +0900

    [sandbox] init script of sandbox returns an improper return code
in status function
    Previous sandbox's init script returns 0 only in status function.
    This return code causes wrong service status report in
system-config-services.

    This fix will change the return code to return a proper code for
system-config-services.

    Signed-off-by: Keigo Noha <knoha@xxxxxxxxxx>

diff --git a/policycoreutils/sandbox/sandbox.init
b/policycoreutils/sandbox/sandbox.init
index 357a7b8..b3979bf 100644
--- a/policycoreutils/sandbox/sandbox.init
+++ b/policycoreutils/sandbox/sandbox.init
@@ -42,15 +42,12 @@ stop() {
 }

 status() {
-        EXIT_CODE=0
        if [ -f "$LOCKFILE" ]; then
            echo "$base is running"
-           EXIT_CODE=0
        else
            echo "$base is stopped"
-           EXIT_CODE=3
        fi
-       exit $EXIT_CODE
+       exit 0
 }

 case "$1" in
===========================

Could you evaluate my patch and consider to merge to master branch?

Best regards,
Keigo

=========================
Keigo Noha
Red Hat
Global Support Services
Senior Technical Support Engineer
==========================
_______________________________________________
Selinux mailing list
Selinux@xxxxxxxxxxxxx
To unsubscribe, send email to Selinux-leave@xxxxxxxxxxxxx.
To get help, send an email containing "help" to Selinux-request@xxxxxxxxxxxxx.



[Index of Archives]     [Selinux Refpolicy]     [Linux SGX]     [Fedora Users]     [Fedora Desktop]     [Yosemite Photos]     [Yosemite Camping]     [Yosemite Campsites]     [KDE Users]     [Gnome Users]

  Powered by Linux