From 0cb1eb842a398e7ef3b7ddabca7f67b7b36bcf66 Mon Sep 17 00:00:00 2001 From: VilhoRaatikka Date: Wed, 28 May 2014 14:03:59 +0300 Subject: [PATCH 1/2] Bug #438, http://bugs.skysql.com/show_bug.cgi?id=438 try to complete the fix. dcb->authlock was double-freed. --- server/modules/protocol/mysql_backend.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/modules/protocol/mysql_backend.c b/server/modules/protocol/mysql_backend.c index 902305c6b..93d7c0df4 100644 --- a/server/modules/protocol/mysql_backend.c +++ b/server/modules/protocol/mysql_backend.c @@ -324,7 +324,7 @@ static int gw_read_backend_event(DCB *dcb) { if (session->client->session == NULL) { rc = 1; - goto return_with_lock; + goto return_rc; } usleep(1); } From 9522d06f9b60b8a7a16d5d6cf47d41be970f9a44 Mon Sep 17 00:00:00 2001 From: VilhoRaatikka Date: Fri, 30 May 2014 11:32:37 +0300 Subject: [PATCH 2/2] Tried explicitly access NULL pointer. --- server/core/dbusers.c | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/server/core/dbusers.c b/server/core/dbusers.c index 41dda5a92..1ef765bc2 100644 --- a/server/core/dbusers.c +++ b/server/core/dbusers.c @@ -229,17 +229,6 @@ getUsers(SERVICE *service, struct users *users) NULL, 0) == NULL)) { - if (server == NULL) - { - LOGIF(LE, (skygw_log_write_flush( - LOGFILE_ERROR, - "Error : Unable to connect to %s:%d, \"%s\"", - server->name, - server->port, - mysql_error(con)))); - mysql_close(con); - return -1; - } server = server->nextdb; } free(dpwd);