-int udp_socks_beforepoll(struct udpsocks *s,
- struct pollfd *fds, int *nfds_io,
- int *timeout_io);
-
-void udp_socks_afterpoll(struct udpcommon *u, struct udpsocks *s,
- struct pollfd *fds, int nfds);
+bool_t udp_make_socket(struct udpcommon *uc, struct udpsock *us,
+ int failmsgclass);
+ /* Caller should have filled in ->addr. Fills in us->fd,
+ ->experienced; updates ->addr. Logs any errors with lg_[v]perror. */
+bool_t udp_import_socket(struct udpcommon *uc, struct udpsock *us,
+ int failmsgclass, int fd);
+ /* Like udp_make_socket, but caller provides fd. fd is not closed
+ on error */
+
+void udp_destroy_socket(struct udpcommon *uc, struct udpsock *us);
+ /* Idempotent. No errors are possible. */
+
+const char *af_name(int af);
+void udp_sock_experienced(struct log_if *lg, struct udpcommon *uc,
+ struct udpsocks *socks, struct udpsock *us,
+ const union iaddr *dest, int af /* 0 means any */,
+ int r, int errnoval);
+
+void udp_socks_register(struct udpcommon *uc, struct udpsocks *socks,
+ const char *desc);
+void udp_socks_deregister(struct udpcommon *uc, struct udpsocks *socks);
+void udp_socks_childpersist(struct udpcommon *uc, struct udpsocks *socks);