Details
Description
I noticed this issue while trying to use TSStringPercentEncode function to encode some data as part of a url. It returns the correct value when there's some characters in the original string to be encoded but if there's no need for any escaping (e.g., just an alpha-numeric string), the return value is short by one character.
I have reproduce this (in trunk) by modifying InkAPITest.cc lines 7500-7502 to contains the test url as follows
const char *url = "http://www.example.com/foo";
const char *url_encoded = "http://www.example.com/foo";
The regression test will then failed with the following
[SDK_API_ENCODING] TSStringPercentEncode : [TestCase1] <<FAIL>>
{ Failed on http://www.example.com/fo != http://www.example.com/foo }