Try again to kill a pptp connection

This commit is contained in:
Jamie Cameron
2009-07-24 11:16:04 -07:00
parent a02ca65ff6
commit c28a16d9d7

View File

@@ -9,8 +9,14 @@ require './pptp-client-lib.pl';
($conn) = grep { $_->[0] eq $in{'tunnel'} } @conns;
$conn || &error($text{'disc_egone'});
&kill_logged('HUP', $conn->[1]) || &error($text{'disc_ekill'});
&webmin_log("disc", undef, $in{'tunnel'});
sleep(3);
@conns = &list_connected();
($conn) = grep { $_->[0] eq $in{'tunnel'} } @conns;
if ($conn) {
# Not dead .. kill harder
&kill_logged('KILL', $conn->[1]);
}
&webmin_log("disc", undef, $in{'tunnel'});
&redirect("");