@@ -419,7 +419,7 @@ void manapi::net::worker::TLS::shutdown_async_(shared_conn conn) {
419419 }
420420
421421 if (err == this->ssl_error_want_write_) {
422- if (this->ssl_bio_flush_write_(conn, s, WORKER_MAX_CNT , false))
422+ if (this->ssl_bio_flush_write_(conn, s, this->config_->max_buffer_stack , false))
423423 goto err;
424424 if (this->flush_write_(conn, true))
425425 goto err;
@@ -455,7 +455,7 @@ void manapi::net::worker::TLS::shutdown_async_(shared_conn conn) {
455455 }
456456
457457 write:
458- if (this->ssl_bio_flush_write_(conn, s, WORKER_MAX_CNT , false))
458+ if (this->ssl_bio_flush_write_(conn, s, this->config_->max_buffer_stack , false))
459459 goto err;
460460 if (this->flush_write_(conn, true))
461461 goto err;
@@ -530,7 +530,7 @@ void manapi::net::worker::TLS::onrecv(const std::shared_ptr<ev::tcp> &watcher, c
530530 err == this->ssl_error_want_read_ ||
531531 err == this->ssl_error_want_write_) {
532532
533- if (this->ssl_bio_flush_write_(conn, data, WORKER_MAX_CNT , false))
533+ if (this->ssl_bio_flush_write_(conn, data, this->config_->max_buffer_stack , false))
534534 goto err;
535535 if (this->flush_write_(conn, true))
536536 goto err;
@@ -740,7 +740,7 @@ int manapi::net::worker::TLS::manapi_do_process(const shared_conn &conn, tls_con
740740 auto const err = this->ssl_get_error_(data->ssl, nread);
741741 if (err == this->ssl_error_want_read_ || err == this->ssl_error_want_write_) {
742742 /* force write all data */
743- if (this->ssl_bio_flush_write_(conn, data, WORKER_MAX_CNT , false)) {
743+ if (this->ssl_bio_flush_write_(conn, data, this->config_->max_buffer_stack , false)) {
744744 return CONN_IO_ERROR;
745745 }
746746
@@ -803,7 +803,7 @@ int manapi::net::worker::TLS::manapi_do_handshake_(const shared_conn &conn, tls_
803803
804804 if (status == this->ssl_error_want_read_ || status == this->ssl_error_want_write_) {
805805 /* force write all data */
806- if (this->ssl_bio_flush_write_(conn, data, WORKER_MAX_CNT , false)) {
806+ if (this->ssl_bio_flush_write_(conn, data, this->config_->max_buffer_stack , false)) {
807807 return CONN_IO_ERROR;
808808 }
809809
@@ -991,7 +991,7 @@ int manapi::net::worker::TLS::ssl_bio_flush_read_(const shared_conn &conn, tls_c
991991 else {
992992 rhs = static_cast<int>(readbytes);
993993
994- if (this->ssl_bio_flush_write_(conn, m, WORKER_MAX_CNT , false)) {
994+ if (this->ssl_bio_flush_write_(conn, m, this->config_->max_buffer_stack , false)) {
995995 return CONN_IO_ERROR;
996996 }
997997
@@ -1032,7 +1032,7 @@ int manapi::net::worker::TLS::ssl_bio_flush_read_(const shared_conn &conn, tls_c
10321032
10331033 if (err == this->ssl_error_want_read_ || err == this->ssl_error_want_write_) {
10341034 /* force write all data */
1035- if (this->ssl_bio_flush_write_(conn, m, WORKER_MAX_CNT , false)) {
1035+ if (this->ssl_bio_flush_write_(conn, m, this->config_->max_buffer_stack , false)) {
10361036 return CONN_IO_ERROR;
10371037 }
10381038
0 commit comments