projects
/
openwrt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[package] uhttpd:
[openwrt.git]
/
package
/
uhttpd
/
src
/
uhttpd-utils.c
diff --git
a/package/uhttpd/src/uhttpd-utils.c
b/package/uhttpd/src/uhttpd-utils.c
index
e65f213
..
caa6b12
100644
(file)
--- a/
package/uhttpd/src/uhttpd-utils.c
+++ b/
package/uhttpd/src/uhttpd-utils.c
@@
-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 != '/') )
;
@@
-621,10
+622,14
@@
struct auth_realm * uh_auth_add(char *path, char *user, char *pass)
min(strlen(pass), sizeof(new->pass) - 1));
}
min(strlen(pass), sizeof(new->pass) - 1));
}
- uh_realm_count++;
+ if( new->pass[0] )
+ {
+ uh_realm_count++;
+ return new;
+ }
}
}
- return
new
;
+ return
NULL
;
}
int uh_auth_check(
}
int uh_auth_check(
This page took
0.019839 seconds
and
4
git commands to generate.