Skip to content

Commit f93daaf

Browse files
committed
adjust pending data in async mode logic
1 parent cee5f5b commit f93daaf

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

modules/proto_tls/proto_tls.c

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -618,11 +618,7 @@ static int proto_tls_send(const struct socket_info* send_sock,
618618
send_sock->last_real_ports->local = c->rcv.dst_port;
619619
send_sock->last_real_ports->remote = c->rcv.src_port;
620620

621-
int pending_data = 0;
622-
lock_get(&c->write_lock);
623-
pending_data = (c->async && c->async->pending)?1:0;
624-
lock_release(&c->write_lock);
625-
tcp_conn_release(c, pending_data);
621+
tcp_conn_release(c, (rlen<len)?1:0);
626622
return rlen;
627623
con_release:
628624
sh_log(c->hist, TCP_SEND2MAIN, "send 1, (%d)", c->refcnt);

0 commit comments

Comments
 (0)