diff options
author | unknown <monty@hundin.mysql.fi> | 2002-08-22 16:50:58 +0300 |
---|---|---|
committer | unknown <monty@hundin.mysql.fi> | 2002-08-22 16:50:58 +0300 |
commit | e4d5597d7e10a213cece255a05be1458f26ad682 (patch) | |
tree | 1f4e2f579c25222692c7c0c682a036ad1e5b3404 /sql/sql_class.h | |
parent | 2466b5b9b3d937fce0d0f8313b7b1e77fa900c86 (diff) | |
download | mariadb-git-e4d5597d7e10a213cece255a05be1458f26ad682.tar.gz |
Fixed bug in wait_for_update() that I had introduced.
Changed option variables to my_bool (to avoid bugs in my_getopt())
Added new thread specific mutex LOCK_delete to be able to free LOCK_thread_count early.
Changed usage of LOCK_thread_count -> LOCK_status for statistics variables
libmysqld/lib_sql.cc:
Removed not needed LOCK
mysql-test/mysql-test-run.sh:
Log name of running test
mysql-test/r/rpl_sporadic_master.result:
Cleaned up test
mysql-test/t/rpl_sporadic_master.test:
cleaned up test
sql/log.cc:
Cleanup.
Fixed bug in wait_for_update() that I had introduced.
sql/mini_client.cc:
Indentation changes.
sql/mysql_priv.h:
Changed option variables to my_bool.
sql/mysqld.cc:
Changed option variables to my_bool.
Removed not used LOCK_server_id
Minor code cleanups.
sql/repl_failsafe.cc:
Minor code cleanups
sql/slave.cc:
Minor code cleanups.
Fixed usage of wait_for_update().
sql/slave.h:
Changed option variables to my_bool.
sql/sql_class.cc:
Added new thread specific mutex LOCK_delete to be able to free LOCK_thread_count early
sql/sql_class.h:
Added new thread specific mutex LOCK_delete to be able to free LOCK_thread_count early
sql/sql_insert.cc:
Do broadcast after unlock()
sql/sql_parse.cc:
Removed not needed LOCK
Changed usage of LOCK_thread_count -> LOCK_status for statistics variables
Changed killing of threads to not lock LOCK_thread_count for long.
sql/sql_repl.cc:
Changed options variables to my_bool
Fixed usage of wait_for_update()
Fixed loop to kill slaves to not lock LOCK_thread_count for long.
Code optimization.
sql/sql_repl.h:
bool -> my_bool
Fixed KICK_SLAVE to use LOCK_delete
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r-- | sql/sql_class.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h index 102320f8f75..f0aa3f09555 100644 --- a/sql/sql_class.h +++ b/sql/sql_class.h @@ -141,8 +141,8 @@ public: // iterating through the log index file int find_log_pos(LOG_INFO* linfo, const char* log_name, - bool need_mutex=1); - int find_next_log(LOG_INFO* linfo, bool need_mutex=1); + bool need_mutex); + int find_next_log(LOG_INFO* linfo, bool need_mutex); int get_current_log(LOG_INFO* linfo); uint next_file_id(); @@ -330,7 +330,8 @@ public: struct sockaddr_in remote; // client socket address struct rand_struct rand; // used for authentication struct system_variables variables; // Changeable local variables - + pthread_mutex_t LOCK_delete; // Locked before thd is deleted + char *query; // Points to the current query, /* A pointer to the stack frame of handle_one_connection(), @@ -410,7 +411,6 @@ public: #endif #ifdef SIGNAL_WITH_VIO_CLOSE Vio* active_vio; - pthread_mutex_t active_vio_lock; #endif ulonglong next_insert_id,last_insert_id,current_insert_id, limit_found_rows; @@ -465,25 +465,25 @@ public: #ifdef SIGNAL_WITH_VIO_CLOSE inline void set_active_vio(Vio* vio) { - pthread_mutex_lock(&active_vio_lock); + pthread_mutex_lock(&LOCK_delete); active_vio = vio; - pthread_mutex_unlock(&active_vio_lock); + pthread_mutex_unlock(&LOCK_delete); } inline void clear_active_vio() { - pthread_mutex_lock(&active_vio_lock); + pthread_mutex_lock(&LOCK_delete); active_vio = 0; - pthread_mutex_unlock(&active_vio_lock); + pthread_mutex_unlock(&LOCK_delete); } inline void close_active_vio() { - pthread_mutex_lock(&active_vio_lock); + pthread_mutex_lock(&LOCK_delete); if (active_vio) { vio_close(active_vio); active_vio = 0; } - pthread_mutex_unlock(&active_vio_lock); + pthread_mutex_unlock(&LOCK_delete); } #endif void awake(bool prepare_to_die); |