From 04d6a987281022bfffb4d03e60d7d19c8135c4bd Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Mon, 18 Feb 2008 23:10:52 +0100 Subject: [PATCH] liboconfig: Make sure that option-strings can always be freed. This resolved a nasty crash when including files. --- src/liboconfig/parser.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/liboconfig/parser.y b/src/liboconfig/parser.y index 5d7b98df..8df2c6e5 100644 --- a/src/liboconfig/parser.y +++ b/src/liboconfig/parser.y @@ -210,8 +210,8 @@ static char *unquote (const char *orig) if ((len < 2) || (ret[0] != '"') || (ret[len - 1] != '"')) return (ret); - ret++; len -= 2; + memmove (ret, ret + 1, len); ret[len] = '\0'; for (i = 0; i < len; i++) -- 2.30.2