Changeset: 28676adeb53b for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/28676adeb53b
Modified Files:
        sql/backends/monet5/sql_optimizer.c
Branch: Mar2025
Log Message:

Fix coverity CID 1417107 issue


diffs (23 lines):

diff --git a/sql/backends/monet5/sql_optimizer.c 
b/sql/backends/monet5/sql_optimizer.c
--- a/sql/backends/monet5/sql_optimizer.c
+++ b/sql/backends/monet5/sql_optimizer.c
@@ -58,7 +58,6 @@ SQLgetSpace(mvc *m, MalBlkPtr mb, int pr
 {
        sql_trans *tr = m->session->tr;
        lng size,space = 0, i;
-       str lasttable = 0;
 
        for (i = 0; i < mb->stop; i++) {
                InstrPtr p = mb->stmt[i];
@@ -84,10 +83,9 @@ SQLgetSpace(mvc *m, MalBlkPtr mb, int pr
                                continue;
 
                        /* we have to sum the cost of all three components of a 
BAT */
-                       if (c && isTable(c->t) && (lasttable == 0 || 
strcmp(lasttable,tname)==0)) {
+                       if (c && isTable(c->t)) {
                                size = SQLgetColumnSize(tr, c, access);
                                space += size;  // accumulate once per table
-                               //lasttable = tname;     invalidate this attempt
                                if( !prepare && size == 0  && ! t->system){
                                        setFunctionId(p, emptybindRef);
                                }
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to