[xml] Bug in xmlNormalizeURIPath

Date view Thread view Subject view Author view

From: Marc Sanfacon (msanfacon@copernic.com)
Date: Thu Feb 01 2001 - 18:50:22 EST


Hi there,
        when calling xmlBuildURI with the following arguments:

        xmlBuildURI("http://www.abc.com", "./");

        the resulting uri is: "http://www.abc.com/./"

        Or it should be "http://www.abc.com/"

        The problem is in xmlNormalizeURIPath:

    while (path[cur] != 0) {
        /*
         * c) All occurrences of "./", where "." is a complete path segment,
         * are removed from the buffer string.
         */
        if ((path[cur] == '.') && (path[cur + 1] == '/')) {
            cur += 2;
+ if (path[cur] == 0) {
+ path[out++] = 0;
+ }
            continue;
        }

Marc.

----
Message from the list xml@rpmfind.net
Archived at : http://xmlsoft.org/messages/
to unsubscribe: echo "unsubscribe xml" | mail  majordomo@rpmfind.net


Date view Thread view Subject view Author view

This archive was generated by hypermail 2b29 : Fri Feb 02 2001 - 02:46:32 EST