mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2025-04-21 12:27:27 +03:00
[package] uhttpd: fix bug in path canonization introduced by r20883
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@20885 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
@@ -420,8 +420,9 @@ static char * canonpath(const char *path, char *path_resolved)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* collapse /x/../ */
|
/* collapse /x/../ */
|
||||||
else if( path_cpy[2] == '.' )
|
else if( (path_cpy[2] == '.') &&
|
||||||
{
|
((path_cpy[3] == '/') || (path_cpy[3] == '\0'))
|
||||||
|
) {
|
||||||
while( (path_res > path_resolved) && (*--path_res != '/') )
|
while( (path_res > path_resolved) && (*--path_res != '/') )
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user