Changeset 8c7a054 in mainline for uspace/srv/net/tl/tcp/state.c
- Timestamp:
- 2011-10-21T15:25:43Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 32aea9f4
- Parents:
- d9ce049
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/tl/tcp/state.c
rd9ce049 r8c7a054 115 115 116 116 /* Wait for data to become available */ 117 while (conn->rcv_buf_used == 0 ) {117 while (conn->rcv_buf_used == 0 && !conn->rcv_buf_fin) { 118 118 log_msg(LVL_DEBUG, "tcp_uc_receive() - wait for data"); 119 119 fibril_condvar_wait(&conn->rcv_buf_cv, &conn->rcv_buf_lock); 120 } 121 122 if (conn->rcv_buf_used == 0) { 123 /* End of data, peer closed connection. */ 124 /* XXX How should RECEIVE signal end of data? */ 125 assert(conn->rcv_buf_fin); 126 *rcvd = 0; 127 *xflags = 0; 128 return; 120 129 } 121 130 … … 147 156 { 148 157 log_msg(LVL_DEBUG, "tcp_uc_close()"); 158 159 conn->snd_buf_fin = true; 160 tcp_tqueue_new_data(conn); 149 161 } 150 162
Note:
See TracChangeset
for help on using the changeset viewer.