Add generic host-up and host-down scripts.
[tinc] / src / graph.c
index 691a5ad..2fc3b74 100644 (file)
@@ -283,6 +283,8 @@ void sssp_bfs(void)
                        asprintf(&envp[5], "REMOTEPORT=%s", port);
                        envp[6] = NULL;
 
                        asprintf(&envp[5], "REMOTEPORT=%s", port);
                        envp[6] = NULL;
 
+                       execute_script(n->status.reachable ? "host-up" : "host-down", envp);
+
                        asprintf(&name,
                                         n->status.reachable ? "hosts/%s-up" : "hosts/%s-down",
                                         n->name);
                        asprintf(&name,
                                         n->status.reachable ? "hosts/%s-up" : "hosts/%s-down",
                                         n->name);