Fix bug: Uri.fromString is crash, when it receive some path ended with "/"

liburiparser uses multi segment data structure to store path.
Though multi segment data structure (maybe) like a signle linked list, our implementation could only treat single segment.

So, when Uri.fromString receive some long path(or ended with "/"?), it crash!