diff options
author | monty@hundin.mysql.fi <> | 2002-06-17 15:00:06 +0300 |
---|---|---|
committer | monty@hundin.mysql.fi <> | 2002-06-17 15:00:06 +0300 |
commit | 0762b00d861ba6dc9fce134b322086ccf21fa0e0 (patch) | |
tree | c0636680f89f14107465f59c1b6c514ae2a45b3f /sql | |
parent | f4da1be1e1107ef5bbceeb2ebb6267d3d201d587 (diff) | |
download | mariadb-git-0762b00d861ba6dc9fce134b322086ccf21fa0e0.tar.gz |
Backported fix from 4.0 which caused core dumps for some complex queries.
Diffstat (limited to 'sql')
-rw-r--r-- | sql/mysqld.cc | 7 | ||||
-rw-r--r-- | sql/opt_range.cc | 3 |
2 files changed, 6 insertions, 4 deletions
diff --git a/sql/mysqld.cc b/sql/mysqld.cc index 08d0f381534..6aad4848242 100644 --- a/sql/mysqld.cc +++ b/sql/mysqld.cc @@ -1121,7 +1121,8 @@ void end_thread(THD *thd, bool put_in_cache) inline void kill_broken_server() { /* hack to get around signals ignored in syscalls for problem OS's */ - if (unix_sock == INVALID_SOCKET || (!opt_disable_networking && ip_sock ==INVALID_SOCKET)) + if (unix_sock == INVALID_SOCKET || + (!opt_disable_networking && ip_sock == INVALID_SOCKET)) { select_thread_in_use = 0; kill_server((void*)MYSQL_KILL_SIGNAL); /* never returns */ @@ -1592,8 +1593,8 @@ pthread_handler_decl(handle_shutdown,arg) abort_loop = 1; // unblock select() - so_cancel( ip_sock); - so_cancel( unix_sock); + so_cancel(ip_sock); + so_cancel(unix_sock); return 0; } diff --git a/sql/opt_range.cc b/sql/opt_range.cc index b95b97d670f..42f20c0f767 100644 --- a/sql/opt_range.cc +++ b/sql/opt_range.cc @@ -1285,7 +1285,8 @@ and_all_keys(SEL_ARG *key1,SEL_ARG *key2,uint clone_flag) } if (key1->type == SEL_ARG::MAYBE_KEY) { - key1->left= &null_element; key1->next=0; + key1->right= key1->left= &null_element; + key1->next= key1->prev= 0; } for (next=key1->first(); next ; next=next->next) { |