Changeset: 1a8c451040b7 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/1a8c451040b7
Modified Files:
        sql/backends/monet5/rel_bin.c
        sql/backends/monet5/rel_physical.c
        sql/backends/monet5/sql.c
        sql/backends/monet5/sql_gencode.c
        sql/backends/monet5/sql_gencode.h
        sql/backends/monet5/sql_rank.c
        sql/backends/monet5/sql_result.c
        sql/backends/monet5/sql_statement.c
        sql/common/sql_types.c
        sql/include/sql_catalog.h
        sql/include/sql_relation.h
        sql/rel.txt
        sql/server/rel_basetable.c
        sql/server/rel_basetable.h
        sql/server/rel_distribute.c
        sql/server/rel_dump.c
        sql/server/rel_exp.c
        sql/server/rel_exp.h
        sql/server/rel_optimize_others.c
        sql/server/rel_optimize_proj.c
        sql/server/rel_optimizer.c
        sql/server/rel_propagate.c
        sql/server/rel_psm.c
        sql/server/rel_rel.c
        sql/server/rel_schema.c
        sql/server/rel_select.c
        sql/server/rel_statistics.c
        sql/server/rel_unnest.c
        sql/server/rel_updates.c
        sql/server/sql_parser.y
        sql/server/sql_semantic.c
        sql/storage/bat/bat_logger.c
        sql/storage/bat/bat_storage.c
        sql/storage/store.c
Branch: nested
Log Message:

merged with default


diffs (truncated from 7110 to 300 lines):

diff --git a/.hgtags b/.hgtags
--- a/.hgtags
+++ b/.hgtags
@@ -843,3 +843,5 @@ ad290be8174693266b1e4eeab06af0266686af38
 ad290be8174693266b1e4eeab06af0266686af38 Mar2025_release
 53b71d71caccc81358785cb852a186500fc95b08 Mar2025_5
 77b1be95dc79fe61215a34b84ed67e7097323977 Mar2025_7
+6d5be335a6c739e61682366f7a84b67b0cfc0be6 Mar2025_9
+6d5be335a6c739e61682366f7a84b67b0cfc0be6 Mar2025_SP1_release
diff --git a/ChangeLog.Mar2025 b/ChangeLog.Mar2025
--- a/ChangeLog.Mar2025
+++ b/ChangeLog.Mar2025
@@ -1,3 +1,7 @@
 # ChangeLog file for devel
 # This file is updated with Maddlog
 
+* Tue Jul  8 2025 Niels Nes <[email protected]>
+- Fixed issue #7655, now the segments keep the number of deleted
+  rows. Only search for reuse when deleted rows are available.
+
diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -1057,6 +1057,12 @@ rm "${RPM_BUILD_ROOT}"%{_unitdir}/monetd
 %endif
 
 %changelog
+* Fri Jul 04 2025 Sjoerd Mullender <[email protected]> - 11.53.9-20250704
+- Rebuilt.
+- GH#7629: monetdbd causes SELinux denial
+- GH#7654: Query remote table that targets remote server table not owned
+  by monetdb default user
+
 * Mon Jun 30 2025 Sjoerd Mullender <[email protected]> - 11.53.7-20250630
 - Rebuilt.
 
diff --git a/clients/odbc/driver/ODBCDbc.c b/clients/odbc/driver/ODBCDbc.c
--- a/clients/odbc/driver/ODBCDbc.c
+++ b/clients/odbc/driver/ODBCDbc.c
@@ -97,10 +97,10 @@ newODBCDbc(ODBCEnv *env)
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid connection handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid connection handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int
+bool
 isValidDbc(ODBCDbc *dbc)
 {
 #ifdef ODBCDEBUG
diff --git a/clients/odbc/driver/ODBCDbc.h b/clients/odbc/driver/ODBCDbc.h
--- a/clients/odbc/driver/ODBCDbc.h
+++ b/clients/odbc/driver/ODBCDbc.h
@@ -93,10 +93,10 @@ ODBCDbc *newODBCDbc(ODBCEnv *env);
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid connection handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid connection handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int isValidDbc(ODBCDbc *dbc);
+bool isValidDbc(ODBCDbc *dbc);
 
 
 /*
diff --git a/clients/odbc/driver/ODBCDesc.c b/clients/odbc/driver/ODBCDesc.c
--- a/clients/odbc/driver/ODBCDesc.c
+++ b/clients/odbc/driver/ODBCDesc.c
@@ -52,10 +52,10 @@ newODBCDesc(ODBCDbc *dbc)
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid statement handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid statement handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int
+bool
 isValidDesc(ODBCDesc *desc)
 {
 #ifdef ODBCDEBUG
diff --git a/clients/odbc/driver/ODBCDesc.h b/clients/odbc/driver/ODBCDesc.h
--- a/clients/odbc/driver/ODBCDesc.h
+++ b/clients/odbc/driver/ODBCDesc.h
@@ -79,7 +79,7 @@ typedef struct {
 #define isIPD(desc)    (isID(desc) && (desc)->Stmt->ImplParamDescr == (desc))
 
 ODBCDesc *newODBCDesc(ODBCDbc *dbc);
-int isValidDesc(ODBCDesc *desc);
+bool isValidDesc(ODBCDesc *desc);
 void addDescError(ODBCDesc *desc, const char *SQLState, const char *errMsg, 
int nativeErrCode);
 ODBCError *getDescError(ODBCDesc *desc);
 
diff --git a/clients/odbc/driver/ODBCEnv.c b/clients/odbc/driver/ODBCEnv.c
--- a/clients/odbc/driver/ODBCEnv.c
+++ b/clients/odbc/driver/ODBCEnv.c
@@ -66,10 +66,10 @@ newODBCEnv(void)
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid environment handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid environment handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int
+bool
 isValidEnv(ODBCEnv *env)
 {
 #ifdef ODBCDEBUG
diff --git a/clients/odbc/driver/ODBCEnv.h b/clients/odbc/driver/ODBCEnv.h
--- a/clients/odbc/driver/ODBCEnv.h
+++ b/clients/odbc/driver/ODBCEnv.h
@@ -67,10 +67,10 @@ ODBCEnv *newODBCEnv(void);
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid environment handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid environment handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int isValidEnv(ODBCEnv *env);
+bool isValidEnv(ODBCEnv *env);
 
 
 /*
diff --git a/clients/odbc/driver/ODBCStmt.c b/clients/odbc/driver/ODBCStmt.c
--- a/clients/odbc/driver/ODBCStmt.c
+++ b/clients/odbc/driver/ODBCStmt.c
@@ -123,10 +123,10 @@ newODBCStmt(ODBCDbc *dbc)
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid statement handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid statement handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int
+bool
 isValidStmt(ODBCStmt *stmt)
 {
 #ifdef ODBCDEBUG
@@ -165,7 +165,7 @@ addStmtError(ODBCStmt *stmt, const char 
  * The error object itself is removed from the error list.
  * The caller is now responsible for freeing the error object memory.
  *
- * Precondition: stmt and error must be valid
+ * Precondition: stmt must be valid
  * Postcondition: returns a ODBCError object or null when no error is 
available.
  */
 ODBCError *
diff --git a/clients/odbc/driver/ODBCStmt.h b/clients/odbc/driver/ODBCStmt.h
--- a/clients/odbc/driver/ODBCStmt.h
+++ b/clients/odbc/driver/ODBCStmt.h
@@ -119,10 +119,10 @@ ODBCStmt *newODBCStmt(ODBCDbc *dbc);
  * and save usage of the handle and prevent crashes as much as possible.
  *
  * Precondition: none
- * Postcondition: returns 1 if it is a valid statement handle,
- *     returns 0 if is invalid and thus an unusable handle.
+ * Postcondition: returns true if it is a valid statement handle,
+ *     returns false if is invalid and thus an unusable handle.
  */
-int isValidStmt(ODBCStmt *stmt);
+bool isValidStmt(ODBCStmt *stmt);
 
 
 /*
diff --git a/cmake/monetdb-versions.cmake b/cmake/monetdb-versions.cmake
--- a/cmake/monetdb-versions.cmake
+++ b/cmake/monetdb-versions.cmake
@@ -57,7 +57,7 @@ set(MAPI_VERSION "${MAPI_VERSION_MAJOR}.
 # extras, and tools/utils/msabaoth.[ch])
 set(MONETDB5_VERSION_MAJOR "37")
 set(MONETDB5_VERSION_MINOR "0")
-set(MONETDB5_VERSION_PATCH "1")
+set(MONETDB5_VERSION_PATCH "2")
 set(MONETDB5_VERSION 
"${MONETDB5_VERSION_MAJOR}.${MONETDB5_VERSION_MINOR}.${MONETDB5_VERSION_PATCH}")
 
 # version of the MONETDBE library (subdirectory tools/monetdbe)
diff --git a/debian/changelog b/debian/changelog
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+monetdb (11.53.9) unstable; urgency=low
+
+  * Rebuilt.
+  * GH#7629: monetdbd causes SELinux denial
+  * GH#7654: Query remote table that targets remote server table not owned
+    by monetdb default user
+
+ -- Sjoerd Mullender <[email protected]>  Fri, 04 Jul 2025 10:41:41 +0200
+
 monetdb (11.53.7) unstable; urgency=low
 
   * Rebuilt.
diff --git a/gdk/gdk_batop.c b/gdk/gdk_batop.c
--- a/gdk/gdk_batop.c
+++ b/gdk/gdk_batop.c
@@ -2985,9 +2985,11 @@ PROPdestroy_nolock(BAT *b)
 void
 PROPdestroy(BAT *b)
 {
-       MT_lock_set(&b->theaplock);
-       PROPdestroy_nolock(b);
-       MT_lock_unset(&b->theaplock);
+       if (b->tprops) {
+               MT_lock_set(&b->theaplock);
+               PROPdestroy_nolock(b);
+               MT_lock_unset(&b->theaplock);
+       }
 }
 
 ValPtr
diff --git a/gdk/gdk_hash.c b/gdk/gdk_hash.c
--- a/gdk/gdk_hash.c
+++ b/gdk/gdk_hash.c
@@ -1350,7 +1350,7 @@ HASHlist(Hash *h, BUN i)
 void
 HASHdestroy(BAT *b)
 {
-       if (b) {
+       if (b && b->thash) {
                Hash *hs;
                MT_rwlock_wrlock(&b->thashlock);
                hs = b->thash;
diff --git a/gdk/gdk_orderidx.c b/gdk/gdk_orderidx.c
--- a/gdk/gdk_orderidx.c
+++ b/gdk/gdk_orderidx.c
@@ -534,7 +534,7 @@ OIDXfree(BAT *b)
 void
 OIDXdestroy(BAT *b)
 {
-       if (b) {
+       if (b && b->torderidx) {
                Heap *hp;
 
                MT_lock_set(&b->batIdxLock);
diff --git a/gdk/gdk_strimps.c b/gdk/gdk_strimps.c
--- a/gdk/gdk_strimps.c
+++ b/gdk/gdk_strimps.c
@@ -1012,7 +1012,7 @@ STRMPincref(Strimps *strimps)
 void
 STRMPdestroy(BAT *b)
 {
-       if (b) {
+       if (b && b->tstrimps) {
                MT_lock_set(&b->batIdxLock);
                if (b->tstrimps == (Strimps *)1) {
                        b->tstrimps = NULL;
diff --git a/monetdb5/mal/mal.h b/monetdb5/mal/mal.h
--- a/monetdb5/mal/mal.h
+++ b/monetdb5/mal/mal.h
@@ -216,7 +216,6 @@ typedef struct MALSTK {
  * It is handy to administer the timing in the stack frame
  * for use in profiling instructions.
  */
-       struct timeval clock;           /* time this stack was created */
        char status;                            /* running 'R' suspended 'S', 
quitting 'Q' */
        int pcup;                                       /* saved pc upon a 
recursive all */
        oid tag;                                        /* unique invocation 
call tag */
diff --git a/monetdb5/mal/mal_interpreter.c b/monetdb5/mal/mal_interpreter.c
--- a/monetdb5/mal/mal_interpreter.c
+++ b/monetdb5/mal/mal_interpreter.c
@@ -512,7 +512,7 @@ runMALsequence(Client cntxt, MalBlkPtr m
        if (startpc + 1 == stoppc) {
                pci = getInstrPtr(mb, startpc);
                if (pci->argc > 16) {
-                       backup = GDKmalloc(pci->argc * sizeof(ValRecord));
+                       backup = GDKmalloc(pci->retc * sizeof(ValRecord));
                        garbage = (int *) GDKzalloc(pci->argc * sizeof(int));
                        if (backup == NULL || garbage == NULL) {
                                GDKfree(backup);
diff --git a/monetdb5/mal/mal_stack.c b/monetdb5/mal/mal_stack.c
--- a/monetdb5/mal/mal_stack.c
+++ b/monetdb5/mal/mal_stack.c
@@ -56,10 +56,24 @@ newGlobalStack(int size)
 {
        MalStkPtr s;
 
-       s = (MalStkPtr) GDKzalloc(stackSize(size));
+       s = (MalStkPtr) GDKmalloc(stackSize(size));
        if (!s)
                return NULL;
        s->stksize = size;
+       s->stktop = s->stkbot = s->stkdepth = s->calldepth = 0;
+    s->keepAlive = s->keepTmps = 0;
+    s->admit = s->wrapup = NULL;
+
+    s->status = 0;
+    s->pcup = 0;
+    s->tag = 0;
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to