Merge branch 'release/1.2.8' into develop
Remove locks for evthr pipe read/write
Accept upper-case "Chunked" in addition to "chunked" for transfer encoding.

Certain clients (particularly Apple's Finder) specify "Chunked" (upper-case)
instead of "chunked" as their desired transfer encoding.

Signed-off-by: Mark Ellzey <socket@gmail.com>
[htparse] Added length checks for various header values

- In some cases, the string comparison functions were not being checked for
  proper length, which could result in reading into garbage data (not past the
  actual buffer end, just the potential of reading a few bytes of a previous loop.

  This should also boost performance a tiny bit as we make sure of things like
  "Connection" is actually 10 bytes before an attempt to do a compare.
Fix up some compiler warnings.
Cleanup
[evthr] re-enable the pipe recv/send locking
Use snprintf for resp hdrs, fallback to evbuffer_add_printf

Since evbuffer_add_printf() adds several steps to the evbuffer additions, we
first attempt to use a small stack buffer and snprintf to fill in the response
haeders, and if it fits, we just simply execute evbuffer_add().

If the snprintf fails (not enough space, for some reason), it will fallback to
the original evbuffer_add_printf()
status_code_to_str no longer uses RB lookups

I don't know why I decided to use RB lookups for status code -> string, it's
just overhead that isn't needed. Swapped it out for a more simple switch/case
method.
Don't call bufferevent_set_timeouts read/write NULL
add 'libdir' support

Signed-off-by: Mark Ellzey <socket@gmail.com>
Add INCLUDE_INSTALL_DIR support
Add back in tree.h
Fix a segfault in regex handling

For a regex pattern like "^/path(/.*)?$" the regex parser may
return "no match", setting the offset to UINT_MAX.

Signed-off-by: Mark Ellzey <socket@gmail.com>
Formatting cleanup
No need for sys/tree include
Release v1.2.9, see ChangeLog for details.
Merge branch 'release/1.2.9'
Merge branch 'master' of github.com:ellzey/libevhtp

Conflicts:
	htparse/htparse.c