fixed bug of cc_utf8_to_utf16() when length!=-1

cc_utf8_to_utf16 doesn't work correctly if length!=-1 and the given char* is not zero-terminated or contains zero.
But the [comment](https://github.com/cocos2d/cocos2d-x/blob/v3/cocos/base/ccUTF8.h#L191) said `length ` is not used any more.