Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions proxy/http3/Http3HeaderFramer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,14 @@ Http3HeaderFramer::Http3HeaderFramer(Http3Transaction *transaction, VIO *source,
http_parser_init(&this->_http_parser);
}

Http3HeaderFramer::~Http3HeaderFramer()
{
_header.destroy();
if (_header_block != nullptr) {
free_MIOBuffer(_header_block);
}
}

Http3FrameUPtr
Http3HeaderFramer::generate_frame()
{
Expand Down
1 change: 1 addition & 0 deletions proxy/http3/Http3HeaderFramer.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ class Http3HeaderFramer : public Http3FrameGenerator
{
public:
Http3HeaderFramer(Http3Transaction *transaction, VIO *source, QPACK *qpack, uint64_t stream_id);
~Http3HeaderFramer();

// Http3FrameGenerator
Http3FrameUPtr generate_frame() override;
Expand Down
1 change: 1 addition & 0 deletions proxy/http3/Http3Session.cc
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ void
HQSession::remove_transaction(HQTransaction *trans)
{
this->_transaction_list.remove(trans);
delete trans;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel like I want to delete transactions on the caller side, but I'll propose the change later.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine, but I wonder why it leaks. Because all transactions in _transaction_list are deleted in the destructor of HQSession. See #9346

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If HQSession::remove_transaction() is called it will remove the transaction from the _transaction_list and it will never be deleted.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, you're right. Go ahead and merge this.


return;
}
Expand Down