don't assume the relpath is really set (merge from #120)
git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-merge-1.4.x@695 152afb58-edef-0310-8abb-c4023f1b3aa9svn/tags/lighttpd-1.4.6
parent
4b63eae57d
commit
57ed250138
|
@ -342,7 +342,8 @@ handler_t http_response_prepare(server *srv, connection *con) {
|
|||
buffer_copy_string_buffer(con->physical.path, con->physical.doc_root);
|
||||
BUFFER_APPEND_SLASH(con->physical.path);
|
||||
buffer_copy_string_buffer(con->physical.basedir, con->physical.path);
|
||||
if (con->physical.rel_path->ptr[0] == '/') {
|
||||
if (con->physical.rel_path->used &&
|
||||
con->physical.rel_path->ptr[0] == '/') {
|
||||
buffer_append_string_len(con->physical.path, con->physical.rel_path->ptr + 1, con->physical.rel_path->used - 2);
|
||||
} else {
|
||||
buffer_append_string_buffer(con->physical.path, con->physical.rel_path);
|
||||
|
|
Loading…
Reference in New Issue