Changes in uspace/srv/net/tcp/sock.c [f4a27304:b243da3] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/tcp/sock.c
rf4a27304 rb243da3 882 882 tcp_sockdata_t *socket; 883 883 tcp_error_t trc; 884 int i; 884 885 int rc; 885 886 … … 897 898 898 899 if (socket->conn != NULL) { 900 /* Close connection */ 899 901 trc = tcp_uc_close(socket->conn); 900 902 if (trc != TCP_EOK && trc != TCP_ENOTEXIST) { … … 905 907 } 906 908 909 if (socket->lconn != NULL) { 910 /* Close listening connections */ 911 for (i = 0; i < socket->backlog; i++) { 912 tcp_uc_set_cstate_cb(socket->lconn[i]->conn, NULL, NULL); 913 trc = tcp_uc_close(socket->lconn[i]->conn); 914 if (trc != TCP_EOK && trc != TCP_ENOTEXIST) { 915 fibril_mutex_unlock(&socket->lock); 916 async_answer_0(callid, EBADF); 917 return; 918 } 919 920 free(socket->lconn[i]); 921 socket->lconn[i] = NULL; 922 } 923 } 924 907 925 /* Grab recv_buffer_lock because of CV wait in tcp_sock_recv_fibril() */ 908 926 fibril_mutex_lock(&socket->recv_buffer_lock);
Note:
See TracChangeset
for help on using the changeset viewer.