5f06bcd0a9
Resolves: CVE-2014-3618
19 lines
521 B
Diff
19 lines
521 B
Diff
diff --git a/src/formisc.c b/src/formisc.c
|
|
index 338733b..c48df52 100644
|
|
--- a/src/formisc.c
|
|
+++ b/src/formisc.c
|
|
@@ -84,12 +84,11 @@ normal: *target++= *start++;
|
|
case '"':*target++=delim='"';start++;
|
|
}
|
|
;{ int i;
|
|
- do
|
|
+ while(*start) /* anything? */
|
|
if((i= *target++= *start++)==delim) /* corresponding delimiter? */
|
|
break;
|
|
else if(i=='\\'&&*start) /* skip quoted character */
|
|
*target++= *start++;
|
|
- while(*start); /* anything? */
|
|
}
|
|
hitspc=2;
|
|
}
|