chiark / gitweb /
server/admin.c: Introduce `a_unlisten' to shut down the admin socket.
[tripe] / server / tripe.h
index a2fdd006416c3ffffe831bdf778ec6e053c95cfa..9d15cb456c2f844cc4b1eb27327ab02a5b7378bf 100644 (file)
@@ -1357,6 +1357,17 @@ extern void a_daemon(void);
 extern void a_listen(const char */*sock*/,
                     uid_t /*u*/, gid_t /*g*/, mode_t /*m*/);
 
+/* --- @a_unlisten@ --- *
+ *
+ * Arguments:  ---
+ *
+ * Returns:    ---
+ *
+ * Use:                Stops listening to the administration socket and removes it.
+ */
+
+extern void a_unlisten(void);
+
 /* --- @a_switcherr@ --- *
  *
  * Arguments:  ---
@@ -1855,6 +1866,31 @@ extern void iv_addreason(void);
 
 extern void iv_rmreason(void);
 
+/*----- The main loop -----------------------------------------------------*/
+
+/* --- @lp_init@ --- *
+ *
+ * Arguments:  ---
+ *
+ * Returns:    ---
+ *
+ * Use:                Initializes the main loop.  Most importantly, this sets up
+ *             the select multiplexor that everything else hooks onto.
+ */
+
+extern void lp_init(void);
+
+/* --- @lp_run@ --- *
+ *
+ * Arguments:  ---
+ *
+ * Returns:    Zero on successful termination; @-1@ if things went wrong.
+ *
+ * Use:                Cranks the main loop until it should be cranked no more.
+ */
+
+extern int lp_run(void);
+
 /*----- Tunnel drivers ----------------------------------------------------*/
 
 #ifdef TUN_LINUX