Changeset: ddfb7d6d22fb for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/ddfb7d6d22fb
Modified Files:
        monetdb5/mal/mal_instruction.c
Branch: Dec2025
Log Message:

Record actual max nr of arguments instead of max space allocated.


diffs (15 lines):

diff --git a/monetdb5/mal/mal_instruction.c b/monetdb5/mal/mal_instruction.c
--- a/monetdb5/mal/mal_instruction.c
+++ b/monetdb5/mal/mal_instruction.c
@@ -895,9 +895,9 @@ pushArgument(MalBlkPtr mb, InstrPtr p, i
                if (mb->errors)
                        return p;
        }                                                       /* protect 
against the case that the instruction is malloced in isolation */
-       if (mb->maxarg < p->maxarg)
-               mb->maxarg = p->maxarg;
        p->argv[p->argc++] = varid;
+       if (mb->maxarg < p->argc)
+               mb->maxarg = p->argc;
        return p;
 }
 
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to