]> git.pld-linux.org Git - packages/php-dirs.git/commitdiff
- don't force 1h if no time found, use only larger value! rel. 9 auto/th/php-dirs-1_1-9 auto/ti/php-dirs-1_1-9
authorTomasz Pala <gotar@pld-linux.org>
Sun, 31 Oct 2010 00:41:10 +0000 (00:41 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    php-dirs.spec -> 1.20
    php-session.sh -> 1.6

php-dirs.spec
php-session.sh

index ab97e98bfe8125580876331f58227a952f9e65ee..7c63d570fc6fa94e8844a92320ff8d4b06c49e4f 100644 (file)
@@ -2,7 +2,7 @@ Summary:        Common dirs for different PHP versions
 Summary(pl.UTF-8):     Wspólne katalogi dla różnych wersji PHP
 Name:          php-dirs
 Version:       1.1
-Release:       8
+Release:       9
 License:       GPL
 Group:         Base
 Source0:       php-session.sh
index bf3000127db431175724b922b6f9674df8527ffd..46a2c019e618befd9d42e5a3b265258549be2952 100644 (file)
@@ -14,12 +14,8 @@ elif [ -r /etc/php4/php.ini ]; then
        RUNTIME4=$(awk -F"=" '/^session.gc_maxlifetime[ \t]*=/ { t=sprintf("%d", ($2/3600)); if (t<1) { t=1; }; print t; exit;}' /etc/php4/php.ini)
 fi
 
-[ -z "$RUNTIME5" ] && RUNTIME5="1h"
+[ -z "$RUNTIME5" ] && [ -z "$RUNTIME4" ] && exit
 
-if [ -n "$RUNTIME5" ]; then
-       /usr/sbin/tmpwatch ${RUNTIME5} /var/run/php
-fi
+[ "${RUNTIME4:-0}" -ge "${RUNTIME5:-0}" ] && RUNTIME=$((RUNTIME4)) || RUNTIME=$((RUNTIME5))
 
-if [ -n "$RUNTIME4" -a "$RUNTIME5" != "$RUNTIME4" ]; then
-       /usr/sbin/tmpwatch ${RUNTIME4} /var/run/php
-fi
+/usr/sbin/tmpwatch ${RUNTIME} /var/run/php
This page took 0.172007 seconds and 4 git commands to generate.