uri decode: fix for warning "use of uninitialised value"

This patch add check in evhttp_decode_uri_internal() that next 2 symbols
are exists in array of chars for decoding, if don't have two next 2
symbols don't try to decode '%FF'
uri decode: changed the test for the existence of the next character

Fix for 64b6eceaba1a4

More info here
https://github.com/azat/libevent/commit/64b6eceaba1a40ab0b175fa9fd9329d3e978ce6e#commitcomment-2714685
Move prototype of evhttp_decode_uri_internal() to http-internal.h

Make it non static, that can be called from tests
Test: decoding just part of string with evhttp_decode_uri_internal()