tinyhttp icon indicating copy to clipboard operation
tinyhttp copied to clipboard

Fix for allowing a header with no value

Open henrikjonhed opened this issue 8 years ago • 1 comments

Possible fix for #6

henrikjonhed avatar Feb 07 '17 13:02 henrikjonhed

I agree with @ledbit regarding the proposed change to support empty header keyvalues.

  • 0x87, 6, 0xC1, 0xC1, 6, 0x87, 0x87, 0xC1, /* state 6: leading whitespace before header value */
  • 0x87, 6, 0xC4, 10, 6, 0x87, 0x87, 0xC1, /* state 6: leading whitespace before header value */ Has this patch been tested? And is there a targeted date for completion / approval of the pull request and merging to the master (since this PR was created in 2017)?

By the way, I think that 10 is intentional - i.e. it is 0x0A rather than 0x10. This would make state 10 the next state. It could have alternatively been shown as 0x0A to make it clearer what the next state is when masked with 0x0F = since the lower 4-bits or nybble of the opcode is the next state, and state values are in the range 0-10.

Gordon Finlay

gfinlay avatar May 26 '21 17:05 gfinlay