luci.http.protocol: Allow posts to contain more than a single chunk 259/head
authorKarl Palsson <karlp@remake.is>
Fri, 21 Nov 2014 18:18:51 +0000 (18:18 +0000)
committerKarl Palsson <karlp@remake.is>
Mon, 24 Nov 2014 09:23:03 +0000 (09:23 +0000)
commit4d0a20bba1a6a6a39e63064ac6cc3a5902570191
tree70b1805d510b1d1963375d321c6a79fabd5e4213
parent614a0f2a156177c5d39032dcdf0ed5ab27172bb9
luci.http.protocol: Allow posts to contain more than a single chunk

The ltn12.pump.step() loop in parse_message_body was incorrectly testing
for EOF, and returning after the first chunk, even if further chunks
were available.  The loop in parse_message_header made the correct
check, and test code making raw ajax json posts now succeeds for posts
>= 2048 bytes.

Signed-off-by: Karl Palsson <karlp@remake.is>
modules/base/luasrc/http/protocol.lua