From: Arne Fitzenreiter Date: Mon, 21 Jun 2010 21:13:06 +0000 (+0200) Subject: Fix ipsecctrl hang at start of a connection. X-Git-Tag: v2.9-beta1~204 X-Git-Url: http://git.ipfire.org/?p=ipfire-2.x.git;a=commitdiff_plain;h=90070fc927c8d8a3a37d0eb818a2c611c4e62fc7 Fix ipsecctrl hang at start of a connection. Fixes bug #0000663 --- diff --git a/src/misc-progs/ipsecctrl.c b/src/misc-progs/ipsecctrl.c index 16fc86ba3b..d974d6c6a5 100644 --- a/src/misc-progs/ipsecctrl.c +++ b/src/misc-progs/ipsecctrl.c @@ -140,6 +140,8 @@ void turn_connection_on (char *name, char *type) { safe_system("/usr/sbin/ipsec reload >/dev/null"); memset(command, 0, STRING_SIZE); + /* give ipsec time to be ready */ + safe_system("/bin/sleep 2"); snprintf(command, STRING_SIZE - 1, "/usr/sbin/ipsec up %s >/dev/null", name); safe_system(command);