diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2015-03-23 06:53:52 +0100 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2015-03-23 06:53:52 +0100 |
commit | 6ab2671259ebfc683af69b57f400457bbbe169eb (patch) | |
tree | fccc96cc9b2e3e51bfb1ea6e82c9d533f109d41c /src/fastd.c | |
parent | 69fc8268d0a17cf3b86b327a78e302f049c194e1 (diff) | |
download | fastd-6ab2671259ebfc683af69b57f400457bbbe169eb.tar fastd-6ab2671259ebfc683af69b57f400457bbbe169eb.zip |
Improve sync/async execution of up/down scripts
Diffstat (limited to 'src/fastd.c')
-rw-r--r-- | src/fastd.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/fastd.c b/src/fastd.c index 19fa10f..5ac1967 100644 --- a/src/fastd.c +++ b/src/fastd.c @@ -207,14 +207,14 @@ static void close_sockets(void) { /** Calls the on-pre-up command */ static inline void on_pre_up(void) { - fastd_shell_command_exec(&conf.on_pre_up, NULL); + fastd_shell_command_exec_sync(&conf.on_pre_up, NULL, NULL); } /** Calls the on-up command */ static inline void on_up(fastd_iface_t *iface) { fastd_shell_env_t *env = fastd_shell_env_alloc(); fastd_shell_env_set_iface(env, iface); - fastd_shell_command_exec(&conf.on_up, env); + fastd_shell_command_exec_sync(&conf.on_up, env, NULL); fastd_shell_env_free(env); } @@ -222,7 +222,7 @@ static inline void on_up(fastd_iface_t *iface) { static inline void on_down(fastd_iface_t *iface) { fastd_shell_env_t *env = fastd_shell_env_alloc(); fastd_shell_env_set_iface(env, iface); - fastd_shell_command_exec(&conf.on_down, env); + fastd_shell_command_exec_sync(&conf.on_down, env, NULL); fastd_shell_env_free(env); } |