From d84444065bd1c05de86012910c16cdf12f95f505 Mon Sep 17 00:00:00 2001 From: slioch Date: Tue, 7 Oct 2008 10:30:47 -0700 Subject: fix for regression bug 3758. added additional check requiring opening and closing quotes before stripping takes place. --- src/delete.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/delete.c b/src/delete.c index 57235d6..3011c12 100644 --- a/src/delete.c +++ b/src/delete.c @@ -82,11 +82,14 @@ static void reset_default(const char *def_val) char tmp_val[1025]; char *ptr = index(def_val,'"'); if (ptr != NULL) { - strcpy(tmp_val,ptr); + strcpy(tmp_val,ptr+1); ptr = rindex(tmp_val,'"'); if (ptr != NULL) { *ptr = '\0'; } + else { + strcpy(tmp_val,def_val); //go with original value. + } } else { strcpy(tmp_val,def_val); -- cgit v1.2.3