Changeset: 39f63e96af65 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=39f63e96af65
Modified Files:
        tools/merovingian/ChangeLog.Dec2011
        tools/merovingian/daemon/merovingian.c
Branch: Dec2011
Log Message:

merovingian: don't try to shutdown internal database 'control'

Skip shutting down the pseudo 'control' database that was introduced for
allowing remote control connections to be made over the same (mapi)
connection served by monetdbd.  This fixes bug #2983.


diffs (39 lines):

diff --git a/tools/merovingian/ChangeLog.Dec2011 
b/tools/merovingian/ChangeLog.Dec2011
--- a/tools/merovingian/ChangeLog.Dec2011
+++ b/tools/merovingian/ChangeLog.Dec2011
@@ -2,6 +2,8 @@
 # This file is updated with mchangelog
 
 * Mon Jan 30 2012 Fabian Groffen <fab...@cwi.nl>
+- Fixed problem where shutdown of monetdbd would lead to shutting down
+  database 'control' which does not exist.  Bug #2983.
 - Fixed issue causing (harmless) 'error reading from control channel'
   messages.
 - Resolved problem where remote start/stop/etc. commands with monetdb
diff --git a/tools/merovingian/daemon/merovingian.c 
b/tools/merovingian/daemon/merovingian.c
--- a/tools/merovingian/daemon/merovingian.c
+++ b/tools/merovingian/daemon/merovingian.c
@@ -1166,12 +1166,12 @@ shutdown:
        /* stop started mservers */
 
        kv = findConfKey(ckv, "exittimeout");
-       if (d != NULL && atoi(kv->val) > 0) {
+       if (d->next != NULL && atoi(kv->val) > 0) {
                dpair t;
                threadlist tl = NULL, tlw = tl;
 
                pthread_mutex_lock(&_mero_topdp_lock);
-               t = d;
+               t = d->next;
                while (t != NULL) {
                        if (tl == NULL) {
                                tl = tlw = malloc(sizeof(struct _threadlist));
@@ -1185,7 +1185,7 @@ shutdown:
                        {
                                Mfprintf(stderr, "%s: unable to create thread 
to terminate "
                                                "database '%s': %s\n",
-                                               argv[0], d->dbname, 
strerror(thret));
+                                               argv[0], t->dbname, 
strerror(thret));
                                tlw->tid = 0;
                        }
 
_______________________________________________
Checkin-list mailing list
Checkin-list@monetdb.org
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to