summaryrefslogtreecommitdiff
path: root/src/buffer.h
diff options
context:
space:
mode:
authorGlenn Strauss <gstrauss@gluelogic.com>2018-11-28 02:12:41 -0500
committerGlenn Strauss <gstrauss@gluelogic.com>2018-11-28 02:12:41 -0500
commit77c01f981725512653c01cde5ca74c11633dfec4 (patch)
treeba511202897b50f59e4ad81fd1df2cee73d35210 /src/buffer.h
parent608026e5aaed1b1c510814d3020aa8241d78f905 (diff)
downloadlighttpd-git-77c01f981725512653c01cde5ca74c11633dfec4.tar.gz
[core] buffer_append_path_len()
concatenate paths, placing single '/' between strings reverts broken commit:b9402283 (thx avij)
Diffstat (limited to 'src/buffer.h')
-rw-r--r--src/buffer.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/buffer.h b/src/buffer.h
index 733cb43a..df461e1a 100644
--- a/src/buffer.h
+++ b/src/buffer.h
@@ -170,6 +170,7 @@ static inline int light_isalnum(int c) {
static inline size_t buffer_string_length(const buffer *b); /* buffer string length without terminating 0 */
static inline size_t buffer_string_space(const buffer *b); /* maximum length of string that can be stored without reallocating */
static inline void buffer_append_slash(buffer *b); /* append '/' no non-empty strings not ending in '/' */
+void buffer_append_path_len(buffer *b, const char *a, size_t alen); /* join strings with '/', if '/' not present */
#define BUFFER_APPEND_STRING_CONST(x, y) \
buffer_append_string_len(x, y, sizeof(y) - 1)