Commit 1b3cf18e authored by Sergei Golubchik's avatar Sergei Golubchik

CONNECT: accessed p[i] outside of the loop

this failed json.test on fulltest2 builder
parent 95dcfede
...@@ -1655,9 +1655,11 @@ bool TYPVAL<PSZ>::Compute(PGLOBAL g, PVAL *vp, int np, OPVAL op) ...@@ -1655,9 +1655,11 @@ bool TYPVAL<PSZ>::Compute(PGLOBAL g, PVAL *vp, int np, OPVAL op)
int i; int i;
for (i = 0; i < np; i++) for (i = 0; i < np; i++)
p[i] = vp[i]->IsNull() ? NULL : vp[i]->GetCharString(val[i]); if (vp[i]->IsNull())
return false;
else
p[i] = vp[i]->GetCharString(val[i]);
if (p[i]) {
switch (op) { switch (op) {
case OP_CNC: case OP_CNC:
assert(np == 1 || np == 2); assert(np == 1 || np == 2);
...@@ -1684,8 +1686,6 @@ bool TYPVAL<PSZ>::Compute(PGLOBAL g, PVAL *vp, int np, OPVAL op) ...@@ -1684,8 +1686,6 @@ bool TYPVAL<PSZ>::Compute(PGLOBAL g, PVAL *vp, int np, OPVAL op)
} // endswitch op } // endswitch op
Null = false; Null = false;
} // endif p[i]
return false; return false;
} // end of Compute } // end of Compute
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment