Interrupt attempts at using dnscrypt if the configuration changes.

This commit is contained in:
Frank Denis
2012-08-02 16:54:29 -07:00
parent 68c7f3d378
commit 6e547708a4
2 changed files with 10 additions and 1 deletions
@@ -0,0 +1,5 @@
#! /bin/sh
. ./common.inc
exec ./handle-control-change.sh
@@ -8,7 +8,7 @@ PAUSE_INCREMENT=0.1
[ ! -e "$DNSCRYPT_FILE" ] && exit 0
pause=0
while :; do
while [ -e "$DNSCRYPT_FILE" ]; do
if [ $pause -lt $PAUSE_MAX ]; then
pause=$((pause + $PAUSE_INCREMENT))
fi
@@ -29,4 +29,8 @@ while :; do
break
done
if [ ! -e "$DNSCRYPT_FILE" ]; then
touch "$CONTROL_DIR"
fi
exec ./exceptions-add.sh