fix header cropping in the HTTP parser

Before this commit all parsed headers were cropped because an invalid length
was passed to __store_header().
 - For primary headers (such as Host, Connection, Cache-Control, etc) that
   was done in __TFW_HTTP_PARSE_HDR_VAL() where the "n" variable was passed
   to __store_header(). The "n" contained only length of the value, but not
   length of the whole header.
 - For raw/other headers (such as User-Agent) the one-by-off was in
   tfw_http_parse_resp(), in the "Req_HdrOther" state. Length of the header
   was calculated via the position pointing to the latest character of the
   header value (but should be pointing to the next character).
fix parsed header string corruption in the HTTP parser

The problem was the incorrectly initialized (or used?) TfwMsg->h_tbl->off field.
That caused raw and "fixed" headers to overwrite each-other during parsing.
Fix h_tbl offset increment upon storing a parsed header.

The offset is only for common headers. Special headers live by their
own constant IDs, so the offset should not be incremented for them
(as it was before this commit).

It is not a major error yet, it just causes a lot of space in the
headers table wasted for non-existing headers.
add basic tests for headers parsing code
Merge pull request #34 from natsys/fix-header-parsing

fix HTTP header parsing
implement basic X-Forwarded-For header support

The commit introduces two major things:
1. The HTTP parser is now able to parse the X-Forwarded-For header and
   put it to the headers table, although t doesn't parse IP addresses
   or distinct Node IDs yet.
2. Client's IP address is added to X-Forwarded-For header of each
   forwarded HTTP request. If there is no such header - it is created,
   if it is already there, then the client's IP is appended to the list.

Also the commit contains fixes for the HTTP parser that used to crop
parsed HTTP headers and write them into each other's locations in the
headers table.

Related to: #5 - Load Balancing
revert HTTP parser fixes that are already merged to master
Fix IP address formatting issues noticed during the code review.
Fix output string temintation in tfw_str_to_cstr()
remove unnecessary buffer zero'ing in tfw_http_append_forwarded_for()

This should be a hot function, so we would like to remove all
unnecessary actions that may affect performance.
optimize tfw_str_to_cstr()  (noticed on code review, minor changes)
resolve conflicts with master (changes from fix-header-parsing branch)
resolve conflicts with master (changes from fix-header-parsing branch)
fix leading LWS and multiple comma parsing in X-Forwarded-For header

1. The problem with leading LWS is the RGEN_LWS() expects to see an
alpha-numeric character after LWS, but we can have '[' in an IPv6
address. Such requests were blocked before this commit.

2. Multiple commas in the header are suspicious. They are not allowed
anymore.