json input support, some shutdown fixes. json needs cleanup.

This commit is contained in:
Ian Gulliver
2016-02-23 13:49:23 -08:00
parent 07d273236d
commit d2e521e90c
14 changed files with 212 additions and 23 deletions

View File

@@ -64,7 +64,8 @@ static void send_hangup(struct send *send) {
if (send->next) {
send->next->prev = send->prev;
}
close(send->peer.fd);
peer_epoll_del((struct peer *) send);
assert(!close(send->peer.fd));
free(send);
}
@@ -94,6 +95,8 @@ void send_cleanup() {
struct send *send = serializer->send_head;
while (send) {
struct send *next = send->next;
peer_epoll_del((struct peer *) send);
assert(!close(send->peer.fd));
free(send);
send = next;
}