ctrlif: Flush/Clear write_queue when closing the control socket

This commit is contained in:
Harald Welte 2013-03-16 10:13:04 +01:00 committed by Holger Hans Peter Freyther
parent 1304b35a64
commit cc6b2d2fa3
1 changed files with 1 additions and 0 deletions

View File

@ -256,6 +256,7 @@ err_index:
static void control_close_conn(struct ctrl_connection *ccon)
{
osmo_wqueue_clear(&ccon->write_queue);
close(ccon->write_queue.bfd.fd);
osmo_fd_unregister(&ccon->write_queue.bfd);
llist_del(&ccon->list_entry);