Willy,
Thierry,

this two patches fix the behaviour of the headers array to be consistent
with Lua standards.

The first one improves the code documentation to be clearer (at least I
was confused by the comments when starting to work on the patch).

The second one actually makes the adjustments. It breaks a bit of backwards
compatibility, but this is not really avoidable. I chose the breakage I
consider "smaller".
Please decide whether you are happy with it and the rationale given in the
commit message.

Backporting depends a bit on what you feel comfortable with. Of course
backporting requires to make the adjustments for non-HTX code as well.

Best regards

Tim Duesterhus (2):
  CLEANUP: lua: Clarify documentation in hlua_http_get_headers
  BUG/MINOR: lua: Make the arrays in the list of headers 1-indexed

 reg-tests/lua/header_1_index.lua |  6 ++++++
 reg-tests/lua/header_1_index.vtc | 29 +++++++++++++++++++++++++++++
 src/hlua.c                       | 23 ++++++++++++++---------
 3 files changed, 49 insertions(+), 9 deletions(-)
 create mode 100644 reg-tests/lua/header_1_index.lua
 create mode 100644 reg-tests/lua/header_1_index.vtc

-- 
2.23.0


Reply via email to