Skip to content

Commit a16b32f

Browse files
authored
Add a missing drop-readable call (#786)
I'm not sure how to add a test for this so the fix here is just in isolation.
1 parent 3f050d4 commit a16b32f

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

  • libc-bottom-half/sources

libc-bottom-half/sources/tcp.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,7 @@ static int tcp_read_eof(void *data) {
173173
__wasilibc_future_block_on(sockets_future_result_void_error_code_read(
174174
state->receive_result, &result),
175175
state->receive_result);
176+
sockets_future_result_void_error_code_drop_readable(state->receive_result);
176177
state->receive_result = 0;
177178
if (result.is_err)
178179
return __wasilibc_socket_error_to_errno(&result.val.err);
@@ -214,6 +215,7 @@ static int tcp_write_eof(void *data) {
214215
__wasilibc_future_block_on(
215216
sockets_future_result_void_error_code_read(state->send_result, &result),
216217
state->send_result);
218+
sockets_future_result_void_error_code_drop_readable(state->send_result);
217219
state->send_result = 0;
218220
if (result.is_err)
219221
return __wasilibc_socket_error_to_errno(&result.val.err);

0 commit comments

Comments
 (0)