Boost logo

Boost Users :

From: Dominique Devienne (ddevienne_at_[hidden])
Date: 2020-12-11 21:18:38


On Fri, Dec 11, 2020 at 8:15 PM Vinnie Falco <vinnie.falco_at_[hidden]> wrote:

> > I'm fairly sure it's user-error, but it's not easy to figure out for a
> Beast novice like myself. --DD
>
> Your response is 200 OK, but you aren't setting Content-Length: 0.
>

Well, I did that on purpose :). I thought
`http::response<http::empty_body>` implied the zero Content-Length...

> For your message, has_content_length() would return false (since you
> aren't setting it). Try adding:
> res.content_length( 0 );
>

Works!

> or
> res.prepare_payload();
>

Works as well.

> Thanks
>

Thank you Vinnie! One less thing to worry about this week-end, thanks
again. --DD



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net