Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

h2: the :scheme pseudo header is not optional #4005

Merged
merged 1 commit into from
Dec 4, 2023

Conversation

dridi
Copy link
Member

@dridi dridi commented Oct 18, 2023

The :scheme pseudo header is not optional in H/2 except when doing CONNECT. There is also a strict requirement for it appear only once.

Signed-off-by: Asad Sajjad Ahmed asadsa@varnish-software.com

Conflicts:
bin/varnishtest/tests/t02025.vtc


This was submitted to the 6.0 branch instead of trunk first. I noticed it thanks to the test case collision while porting #3998 to the 6.0 branch.

The :scheme pseudo header is not optional in H/2 except when doing CONNECT.
There is also a strict requirement for it appear only once.

Signed-off-by: Asad Sajjad Ahmed <asadsa@varnish-software.com>

Conflicts:
	bin/varnishtest/tests/t02025.vtc
Comment on lines +604 to +610
int scheme_seen;
h2_error h2e;
ssize_t cl;

ASSERT_RXTHR(h2);
assert(r2->state == H2_S_OPEN);
scheme_seen = h2->decode->flags & H2H_DECODE_FLAG_SCHEME_SEEN;
Copy link
Member Author

Choose a reason for hiding this comment

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

I'm not convinced we need this local variable when we use it just once. I will add a separate commit to maintain the authorship of this one.

Copy link
Member

Choose a reason for hiding this comment

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

fwiw, I think wrt machine code the local variable makes no difference

@nigoroll
Copy link
Member

nigoroll commented Dec 4, 2023

bugwash: ✅

@dridi dridi merged commit 1ab71cf into varnishcache:master Dec 4, 2023
14 of 15 checks passed
@dridi dridi deleted the dublicate branch December 4, 2023 16:59
@dridi
Copy link
Member Author

dridi commented Dec 4, 2023

ca22c74

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

Successfully merging this pull request may close these issues.

None yet

3 participants