Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@kazuho
Copy link
Member

@kazuho kazuho commented Oct 2, 2019

The on-the-fly compressor typically emits multiple vectors.

In #1992 that got merged as part of #1846, we switched the vector type being used for sending response chunks from h2o_iovec_t to h2o_sendvec_t. The size of the structs are different.

However, we failed to make the corresponding change in HTTP/2 handler, resulting in corrupt list of vectors when multiple vectors are split into different calls to writev.

Reported in #2135.

PS. This is a good (bad) example in showing the danger of using typeof(typename) in memory-related function calls (e.g., malloc, memcpy, memmove). Do we want to do a review and rewrite those?

… response when mutiple buffers are pushed (by on-the-fly gzip, but maybe others too)
@kazuho kazuho merged commit 1d12c35 into master Oct 2, 2019
@kazuho kazuho mentioned this pull request Oct 2, 2019
@deweerdt
Copy link
Member

deweerdt commented Oct 2, 2019

Amazing, good catch, @kazuho

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants