From 98ccaf67ae109bc50f52516ac5c9ef39133930f3 Mon Sep 17 00:00:00 2001 From: Arne Fitzenreiter Date: Sat, 29 May 2010 23:32:49 +0200 Subject: [PATCH] Fix vpn-watch hang after a connection was restartet. --- config/rootfiles/core/38/filelists/files | 1 + src/scripts/vpn-watch | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/config/rootfiles/core/38/filelists/files b/config/rootfiles/core/38/filelists/files index 49a688689c..ac7e56f856 100644 --- a/config/rootfiles/core/38/filelists/files +++ b/config/rootfiles/core/38/filelists/files @@ -133,3 +133,4 @@ var/ipfire/updatexlrator/bin/lscache var/ipfire/updatexlrator/updxlrator-lib.pl var/log/cache var/log/updatexlrator +usr/local/bin/vpn-watch diff --git a/src/scripts/vpn-watch b/src/scripts/vpn-watch index 74a4dc5c1a..c533f064e3 100755 --- a/src/scripts/vpn-watch +++ b/src/scripts/vpn-watch @@ -1,6 +1,6 @@ #!/usr/bin/perl ################################################## -##### VPN-Watch.pl Version 0.4 ##### +##### VPN-Watch.pl Version 0.4a ##### ################################################## # # # VPN-Watch is part of the IPFire Firewall # @@ -55,7 +55,7 @@ foreach (@vpnsettings){ if ( $established eq '' || $connected eq '' ){ logger("Remote IP for host $remotehostname has changed or no connection is established, restarting connection to $remoteip."); system("/usr/local/bin/ipsecctrl S $settings[0]"); - next; + last; #all connections will reloaded } if ($debug){logger("All connections may be fine nothing was done.");} } -- 2.39.2