aboutsummaryrefslogtreecommitdiff
path: root/server.c
diff options
context:
space:
mode:
Diffstat (limited to 'server.c')
-rw-r--r--server.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/server.c b/server.c
index 60d1da8..79c7d9c 100644
--- a/server.c
+++ b/server.c
@@ -514,6 +514,8 @@ fmt_sbuf(const char *fmt, struct client *c, const char *path)
strlcat(c->sbuf, "%", sizeof(c->sbuf));
break;
case 'p':
+ if (*path != '/')
+ strlcat(c->sbuf, "/", sizeof(c->sbuf));
strlcat(c->sbuf, path, sizeof(c->sbuf));
break;
case 'q':