This is an automated email from the ASF dual-hosted git repository.

zwoop pushed a commit to branch 9.0.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/9.0.x by this push:
     new 64d6a54  Signal WRITE_COMPLETE regardless of transmission progress 
(#7062)
64d6a54 is described below

commit 64d6a54e3f7f543c61f1c2cf140b99072c4c1a44
Author: Masakazu Kitajo <[email protected]>
AuthorDate: Thu Aug 6 08:17:25 2020 +0900

    Signal WRITE_COMPLETE regardless of transmission progress (#7062)
    
    (cherry picked from commit 2219cee51ee943b13ffb572b00fb98d38b116feb)
---
 proxy/http3/Http3Transaction.cc | 14 +++++++++-----
 1 file changed, 9 insertions(+), 5 deletions(-)

diff --git a/proxy/http3/Http3Transaction.cc b/proxy/http3/Http3Transaction.cc
index fc9d066..6ffb895 100644
--- a/proxy/http3/Http3Transaction.cc
+++ b/proxy/http3/Http3Transaction.cc
@@ -379,21 +379,25 @@ Http3Transaction::state_stream_open(int event, void 
*edata)
     Http3TransVDebug("%s (%d)", get_vc_event_name(event), event);
     this->_process_read_vio();
     this->_data_handler->finalize();
+    // always signal regardless of progress
     this->_signal_read_event();
     this->_stream_io->read_reenable();
     break;
   case VC_EVENT_WRITE_READY:
-  case VC_EVENT_WRITE_COMPLETE: {
     Http3TransVDebug("%s (%d)", get_vc_event_name(event), event);
-    int64_t len = this->_process_write_vio();
     // if no progress, don't need to signal
-    if (len > 0) {
+    if (this->_process_write_vio() > 0) {
       this->_signal_write_event();
     }
     this->_stream_io->write_reenable();
-
     break;
-  }
+  case VC_EVENT_WRITE_COMPLETE:
+    Http3TransVDebug("%s (%d)", get_vc_event_name(event), event);
+    this->_process_write_vio();
+    // always signal regardless of progress
+    this->_signal_write_event();
+    this->_stream_io->write_reenable();
+    break;
   case VC_EVENT_EOS:
   case VC_EVENT_ERROR:
   case VC_EVENT_INACTIVITY_TIMEOUT:

Reply via email to