Skip to content

generate: add space to string_of_status#754

Merged
mseri merged 3 commits into
mirage:masterfrom
mseri:fix-752
Mar 16, 2021
Merged

generate: add space to string_of_status#754
mseri merged 3 commits into
mirage:masterfrom
mseri:fix-752

Conversation

@mseri
Copy link
Copy Markdown
Collaborator

@mseri mseri commented Mar 12, 2021

This is required by the spec.
The change could have gone into the response module,
adding a specific logic checking the presence of the
space before the string termination, but it seemed
cleaner to add it here.

Should fix #752.

Signed-off-by: Marcello Seri marcello.seri@gmail.com

This is required by the spec.
The change could have gone into the response module,
adding a specific logic checking the presence of the
space before the string termination, but it seemed
cleaner to add it here.

Signed-off-by: Marcello Seri <marcello.seri@gmail.com>
@mseri mseri closed this Mar 12, 2021
@mseri mseri deleted the fix-752 branch March 12, 2021 23:28
@mseri mseri restored the fix-752 branch March 12, 2021 23:59
@mseri mseri reopened this Mar 12, 2021
@mseri
Copy link
Copy Markdown
Collaborator Author

mseri commented Mar 13, 2021

We can produce a better response with this change in response.ml: https://github.com/mseri/ocaml-cohttp/blob/15f6807b66c8ec1a1640ad7d24f0b05e4557591d/cohttp/src/response.ml#L107-L120 but it probably adds extra complexity for no reason.

as suggested in the issue report

Signed-off-by: Marcello Seri <marcello.seri@gmail.com>
@mseri mseri mentioned this pull request Mar 15, 2021
Copy link
Copy Markdown
Member

@avsm avsm left a comment

Choose a reason for hiding this comment

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

The simpler one looks good to me -- no need to put extra bytes over the wire when the longer description can be looked up easily enough :-)

Just needs a CHANGES entry and good to merge.

Signed-off-by: Marcello Seri <marcello.seri@gmail.com>
@mseri mseri merged commit 0cd7a57 into mirage:master Mar 16, 2021
@mseri mseri deleted the fix-752 branch March 16, 2021 10:25
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.

Invalid HTTP Status line when a custom status code is used

3 participants