Commit d8122578 authored by Tom Lane's avatar Tom Lane

Fix bogus sizeof calculations.

Noted by Coverity.  Typo in 27cc7cd2, so back-patch to v12
as that was.
parent 3d9a3ef5
......@@ -2912,7 +2912,7 @@ EvalPlanQualStart(EPQState *epqstate, Plan *planTree)
{
Assert(epqstate->relsubs_done != NULL);
memset(epqstate->relsubs_rowmark, 0,
sizeof(rtsize * sizeof(ExecAuxRowMark *)));
rtsize * sizeof(ExecAuxRowMark *));
memset(epqstate->relsubs_done, 0,
rtsize * sizeof(bool));
}
......@@ -2966,7 +2966,7 @@ EvalPlanQualEnd(EPQState *epqstate)
if (epqstate->tuple_table != NIL)
{
memset(epqstate->relsubs_slot, 0,
sizeof(rtsize * sizeof(TupleTableSlot *)));
rtsize * sizeof(TupleTableSlot *));
ExecResetTupleTable(epqstate->tuple_table, true);
epqstate->tuple_table = NIL;
}
......
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