Second possible fix for bug #896

v1.4.0
René Cannaò 9 years ago
parent 817cda3f12
commit 922a51f902

@ -2400,7 +2400,7 @@ __run_skip_1a:
mysess->thread=NULL;
// we first delete the association in sessmap
sessmap.erase(mysess->thread_session_id);
if (mysql_sessions->len) {
if (mysql_sessions->len > 1) {
// take the last element and adjust the map
MySQL_Session *mysess_last=(MySQL_Session *)mysql_sessions->index(mysql_sessions->len-1);
sessmap[mysess_last->thread_session_id]=sess_pos;
@ -2445,7 +2445,7 @@ __run_skip_1a:
mysess->thread=NULL;
// we first delete the association in sessmap
sessmap.erase(mysess->thread_session_id);
if (mysql_sessions->len) {
if (mysql_sessions->len > 1) {
// take the last element and adjust the map
MySQL_Session *mysess_last=(MySQL_Session *)mysql_sessions->index(mysql_sessions->len-1);
sessmap[mysess_last->thread_session_id]=sess_pos;

Loading…
Cancel
Save