[Pkg-ossec-devel] [SCM] Git repository for pkg-ossec branch, debian, updated. f89fb2c00b1a2606035e5cd0e35b4ebe99f049ac

Javier Fernandez-Sanguino jfs at debian.org
Wed Aug 29 12:57:46 UTC 2012


The following commit has been merged in the debian branch:
commit 26037701781e234f6c349d2c143057550a28c698
Author: Javier Fernandez-Sanguino <jfs at debian.org>
Date:   Wed Aug 29 00:50:13 2012 +0200

    New patch to make the control agent return the status value on exit

diff --git a/debian/patches/06-control-return-status-value b/debian/patches/06-control-return-status-value
new file mode 100644
index 0000000..9d2a878
--- /dev/null
+++ b/debian/patches/06-control-return-status-value
@@ -0,0 +1,30 @@
+Index: pkg-ossec/src/init/ossec-server.sh
+===================================================================
+--- pkg-ossec.orig/src/init/ossec-server.sh	2012-08-29 00:47:17.000000000 +0200
++++ pkg-ossec/src/init/ossec-server.sh	2012-08-29 00:49:19.000000000 +0200
+@@ -189,14 +189,17 @@
+ # Status function
+ status()
+ {
++    retvalue=0
+     for i in ${DAEMONS}; do
+         pstatus ${i};
+         if [ $? = 0 ]; then
+             echo "${i} not running..."
++	    retvalue=1 # We return with error if some of the components is not running
+         else
+             echo "${i} is running..."
+         fi
+     done             
++    return $retvalue
+ }
+ 
+ testconfig()
+@@ -322,6 +325,7 @@
+ 	;;
+   status)
+     status
++    exit $?
+ 	;;
+   help)  
+     help
diff --git a/debian/patches/series b/debian/patches/series
index 6e366af..0a6ac72 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -4,3 +4,4 @@
 03-disable-chroot-default.patch
 04-control-lock-removal
 05-standard-pidfile-location
+06-control-return-status-value

-- 
Git repository for pkg-ossec



More information about the Pkg-ossec-devel mailing list