1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-03-19 14:50:07 +03:00

fixed 2 uri normalization bugs on '//' reduction Daniel

* uri.c: fixed 2 uri normalization bugs on '//' reduction
Daniel
This commit is contained in:
Daniel Veillard 2001-06-26 07:47:23 +00:00
parent 23793845ed
commit fcbd74a2d0
2 changed files with 11 additions and 0 deletions

View File

@ -1,3 +1,7 @@
Tue Jun 26 09:46:29 CEST 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
* uri.c: fixed 2 uri normalization bugs on '//' reduction
Mon Jun 25 18:06:23 CEST 2001 Daniel Veillard <Daniel.Veillard@imag.fr>
* include/libxml/Makefile.am: Laszlo Peter pointed out that

7
uri.c
View File

@ -774,6 +774,9 @@ xmlNormalizeURIPath(char *path) {
*/
if ((cur[0] == '.') && (cur[1] == '/')) {
cur += 2;
/* '//' normalization should be done at this point too */
while (cur[0] == '/')
cur++;
continue;
}
@ -790,6 +793,10 @@ xmlNormalizeURIPath(char *path) {
goto done_cd;
(out++)[0] = (cur++)[0];
}
/* nomalize // */
while ((cur[0] == '/') && (cur[1] == '/'))
cur++;
(out++)[0] = (cur++)[0];
}
done_cd: