Fri, 02 Oct 2015 14:42:47 +0200
fixed href comparison bug
libidav/methods.c | file | annotate | diff | comparison | revisions |
--- a/libidav/methods.c Fri Oct 02 13:29:32 2015 +0200 +++ b/libidav/methods.c Fri Oct 02 14:42:47 2015 +0200 @@ -365,7 +365,14 @@ ret = 1; } } - } + } else if(href_r.length == href_s.length + 1) { + if(href_r.ptr[href_r.length-1] == '/') { + href_r.length--; + if(!sstrcmp(href_s, href_r)) { + ret = 1; + } + } + } free(href_s.ptr); free(href_r.ptr);