X-Git-Url: http://git.ipfire.org/?p=ipfire-2.x.git;a=blobdiff_plain;f=src%2Fmisc-progs%2Fipsecctrl.c;h=eb3fc4984f22ccfe4e46a2f2f804a60bf4386559;hp=570fdebab4583e3c10f6d8f2a56df42d3cfbed57;hb=e1297cbb7659618c526fdc1ab07e97f57f55fd78;hpb=47a83092b5a6f2fa13d1c95de75b7bea4eb90da2 diff --git a/src/misc-progs/ipsecctrl.c b/src/misc-progs/ipsecctrl.c index 570fdebab4..eb3fc4984f 100644 --- a/src/misc-progs/ipsecctrl.c +++ b/src/misc-progs/ipsecctrl.c @@ -44,6 +44,14 @@ void usage() { fprintf (stderr, "\t\tI : Print Statusinfo\n"); } +static void ipsec_reload() { + /* Re-read all configuration files and secrets and + * reload the daemon (#10339). + */ + safe_system("/usr/sbin/ipsec rereadall >/dev/null 2>&1"); + safe_system("/usr/sbin/ipsec reload >/dev/null 2>&1"); +} + /* ACCEPT the ipsec protocol ah, esp & udp (for nat traversal) on the specified interface */ @@ -174,14 +182,6 @@ void turn_connection_off (char *name) { ipsec_reload(); } -void ipsec_reload() { - /* Re-read all configuration files and secrets and - * reload the daemon (#10339). - */ - safe_system("/usr/sbin/ipsec rereadall >/dev/null 2>&1"); - safe_system("/usr/sbin/ipsec reload >/dev/null 2>&1"); -} - int main(int argc, char *argv[]) { char configtype[STRING_SIZE]; char redtype[STRING_SIZE] = "";