You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@trafficserver.apache.org by ma...@apache.org on 2017/08/10 07:15:10 UTC
[trafficserver] branch quic-latest updated: Fix a runtime error on
Fedora 26
This is an automated email from the ASF dual-hosted git repository.
maskit pushed a commit to branch quic-latest
in repository https://gitbox.apache.org/repos/asf/trafficserver.git
The following commit(s) were added to refs/heads/quic-latest by this push:
new fc797a0 Fix a runtime error on Fedora 26
fc797a0 is described below
commit fc797a0838dd8d6c62a9a068b1e8c730d98ac780
Author: Masakazu Kitajo <ma...@apache.org>
AuthorDate: Thu Aug 10 16:11:46 2017 +0900
Fix a runtime error on Fedora 26
operator[] of std::map try to create a value if the key doesn't exist, which
we don't want to because it would be a shared_ptr. Use find() instead.
---
iocore/net/quic/QUICStream.cc | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/iocore/net/quic/QUICStream.cc b/iocore/net/quic/QUICStream.cc
index 1e82095..f80ed0f 100644
--- a/iocore/net/quic/QUICStream.cc
+++ b/iocore/net/quic/QUICStream.cc
@@ -235,9 +235,10 @@ QUICStream::_write_to_read_vio(std::shared_ptr<const QUICStreamFrame> frame)
void
QUICStream::_reorder_data()
{
- while (auto frame = _request_stream_frame_buffer[this->_request_buffer_offset]) {
- this->_request_stream_frame_buffer.erase(this->_request_buffer_offset);
- this->_write_to_read_vio(frame);
+ auto frame = _request_stream_frame_buffer.find(this->_request_buffer_offset);
+ while (frame != this->_request_stream_frame_buffer.end()) {
+ this->_write_to_read_vio(frame->second);
+ frame = _request_stream_frame_buffer.find(this->_request_buffer_offset);
}
}
--
To stop receiving notification emails like this one, please contact
['"commits@trafficserver.apache.org" <co...@trafficserver.apache.org>'].