cjoudrey / gluahttp

gluahttp: an http module for gopher-lua
MIT License
59 stars 23 forks source link

Set Content-Length header when posting a form #10

Closed chrsm closed 8 years ago

chrsm commented 8 years ago

Some servers will reject a POST when there is no content-length header (or if it is inaccurate). This header cannot be set from the header options within lua (I tracked "why" down when I committed this, but have since forgotten).

erikdubbelboer commented 8 years ago

I think this can be merged safely.

cjoudrey commented 8 years ago

Thanks for the patch. Makes sense to me. We might want to add a test for it before merging?

chrsm commented 8 years ago

Hi,

Currently on vacation but I will add a test when I get back next week.

On Jun 25, 2016, at 9:14 AM, Christian Joudrey notifications@github.com wrote:

Thanks for the patch. Makes sense to me. We might want to add a test for it before merging?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

erikdubbelboer commented 8 years ago

@chrsm I created a pull request including tests, if @cjoudrey and you don't mind I'll merge this one.

erikdubbelboer commented 8 years ago

Forgot to link the new pull: https://github.com/cjoudrey/gluahttp/pull/14

cjoudrey commented 8 years ago

Closing this in favour of #14. Thanks @chrsm for pointing this out.