int _lazy_bridge_setup(Bridge* bridge) { if (!bridge_is_initialized(bridge)) { if (bridge_setup(bridge) == ERROR) { return ERROR; } } return SUCCESS; }
static void main_process(const char *ns_pid, const char *address, int fd) { const char *container = "LanQPreactor"; if (bridge_setup(address, container, ns_pid) < 0) exit(1); if (fd > 0) { write(fd, "0", 1); // Success signal close(fd); } bridge_run(500000); }