commit:     73f459d68b6c2a659511f2ab2ea085b3ca997f9d
Author:     Brian Evans <grknight <AT> tuffmail <DOT> com>
AuthorDate: Tue Jul 25 01:40:55 2017 +0000
Commit:     Brian Evans <grknight <AT> gentoo <DOT> org>
CommitDate: Tue Jul 25 01:40:55 2017 +0000
URL:        https://gitweb.gentoo.org/proj/eselect-php.git/commit/?id=73f459d6

Don't allow restart with a bad config

 doc/php-fpm.example.init.in.in | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/doc/php-fpm.example.init.in.in b/doc/php-fpm.example.init.in.in
index 04fb26f..859ee5a 100644
--- a/doc/php-fpm.example.init.in.in
+++ b/doc/php-fpm.example.init.in.in
@@ -49,7 +49,15 @@ configtest() {
 }
 
 start_pre() {
-    configtest || return $?
+    if [ "${RC_CMD}" != "restart" ] ; then
+        configtest || return $?
+    fi
+}
+
+stop_pre() {
+    if [ "${RC_CMD}" = "restart" ] ; then
+        configtest || return $?
+    fi
 }
 
 reload() {

Reply via email to