diff options
author | Frederic Lepied <flepied@mandriva.com> | 2002-03-06 04:11:58 +0000 |
---|---|---|
committer | Frederic Lepied <flepied@mandriva.com> | 2002-03-06 04:11:58 +0000 |
commit | 504ab3efd8740ac442c4aed462bca175ae28c8fb (patch) | |
tree | 38fb61946c8f79825da1be19bc062ca70a7c2d08 /share | |
parent | 40a29faeeeeafc983028f51e6c17c64117e301c3 (diff) | |
download | msec-504ab3efd8740ac442c4aed462bca175ae28c8fb.tar msec-504ab3efd8740ac442c4aed462bca175ae28c8fb.tar.gz msec-504ab3efd8740ac442c4aed462bca175ae28c8fb.tar.bz2 msec-504ab3efd8740ac442c4aed462bca175ae28c8fb.tar.xz msec-504ab3efd8740ac442c4aed462bca175ae28c8fb.zip |
don't run twice
Diffstat (limited to 'share')
-rwxr-xr-x | share/msec | 20 |
1 files changed, 20 insertions, 0 deletions
@@ -6,8 +6,28 @@ # Version : $Id$ # Author : Frederic Lepied # Created On : Thu Dec 13 11:36:50 2001 +# Purpose : entry script to run hardness script or change +# the security level. #--------------------------------------------------------------- +LCK=/var/run/msec.pid + +function cleanup() { + rm -f $LCK +} + +if [ -f $LCK ]; then + if [ -d /proc/`cat $LCK` ]; then + exit 0 + else + rm -f $LCK + fi +fi + +echo -n $$ > $LCK + +trap cleanup 0 + MSEC=/usr/share/msec/msec.py OPT="" |