From 131c676fb6fc6323089acd45741a4659ffe888fc Mon Sep 17 00:00:00 2001 From: Phil Jones Date: Fri, 24 Jun 2022 16:23:09 +0100 Subject: Allow double-quoted strings in config file. --- src/config.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/config.c') diff --git a/src/config.c b/src/config.c index 79d0fae..2239b31 100644 --- a/src/config.c +++ b/src/config.c @@ -217,6 +217,10 @@ char *strip(const char *str) if (end < start) { return NULL; } + if (str[start] == '"' && str[end] == '"' && end > start) { + start++; + end--; + } size_t len = end - start + 1; char *buf = xcalloc(len + 1, 1); strncpy(buf, str + start, len); -- cgit v1.2.3