From f3433b11c1e3a2ec3d6f7b332afa5cf5f69dc360 Mon Sep 17 00:00:00 2001 From: j8takagi Date: Wed, 10 Feb 2010 23:25:30 +0900 Subject: [PATCH 1/1] =?utf8?q?=E3=82=AA=E3=83=9A=E3=83=A9=E3=83=B3?= =?utf8?q?=E3=83=89=E9=95=B7=E5=8F=96=E5=BE=97=E6=99=82=E3=81=AE=E3=83=90?= =?utf8?q?=E3=82=B0=E3=82=92=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/token.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/token.c b/src/token.c index 2757a7b..54ebf3f 100644 --- a/src/token.c +++ b/src/token.c @@ -6,7 +6,7 @@ OPD *opdtok(const char *str) { OPD *opd = malloc(sizeof(OPD)); char *p, *q, *sepp; - int sepc = ',', len = 0; + int sepc = ',', len; bool quoting = false; opd->opdc = 0; @@ -15,6 +15,7 @@ OPD *opdtok(const char *str) } p = q = strdup(str); do { + len = 0; /* オペランド数が多すぎる場合はエラー */ if(opd->opdc >= OPDSIZE) { setcerr(117, str); /* operand is too many */ -- 2.18.0