summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorunknown <malff/marcsql@weblab.(none)>2007-07-27 12:22:00 -0600
committerunknown <malff/marcsql@weblab.(none)>2007-07-27 12:22:00 -0600
commitced93a5cc8fb3822e63a20359aa68cc54ffb2d4a (patch)
tree00a61c4cc45ca89121a957283226b4b666b7a0fc /storage
parent5a03bfbbce3f8bb9b7a3e9655d167ea6625e654e (diff)
parentcc5b3745661bdf5328c87e7045abe8ec7d9b1522 (diff)
downloadmariadb-git-ced93a5cc8fb3822e63a20359aa68cc54ffb2d4a.tar.gz
Merge malff@bk-internal.mysql.com:/home/bk/mysql-5.1-runtime
into weblab.(none):/home/marcsql/TREE/mysql-5.1-25422-d client/mysqldump.c: Auto merged mysql-test/r/log_state.result: Auto merged mysql-test/r/show_check.result: Auto merged mysql-test/t/show_check.test: Auto merged sql/mysql_priv.h: Auto merged sql/share/errmsg.txt: Auto merged sql/sp.cc: Auto merged
Diffstat (limited to 'storage')
-rw-r--r--storage/csv/ha_tina.cc12
-rw-r--r--storage/csv/ha_tina.h5
-rw-r--r--storage/myisam/ha_myisam.cc36
-rw-r--r--storage/myisam/ha_myisam.h5
4 files changed, 1 insertions, 57 deletions
diff --git a/storage/csv/ha_tina.cc b/storage/csv/ha_tina.cc
index 34c1fcde58d..00ca2a6c07f 100644
--- a/storage/csv/ha_tina.cc
+++ b/storage/csv/ha_tina.cc
@@ -786,18 +786,6 @@ void ha_tina::update_status()
}
-bool ha_tina::check_if_locking_is_allowed(uint sql_command,
- ulong type, TABLE *table,
- uint count, uint current,
- uint *system_count,
- bool called_by_privileged_thread)
-{
- if (!called_by_privileged_thread)
- return check_if_log_table_locking_is_allowed(sql_command, type, table);
-
- return TRUE;
-}
-
/*
Open a database file. Keep in mind that tables are caches, so
this will not be called for every request. Any sort of positions
diff --git a/storage/csv/ha_tina.h b/storage/csv/ha_tina.h
index 5bb3e9a79a0..5ce09783b9b 100644
--- a/storage/csv/ha_tina.h
+++ b/storage/csv/ha_tina.h
@@ -131,11 +131,6 @@ public:
*/
ha_rows estimate_rows_upper_bound() { return HA_POS_ERROR; }
- virtual bool check_if_locking_is_allowed(uint sql_command,
- ulong type, TABLE *table,
- uint count, uint current,
- uint *system_count,
- bool called_by_logger_thread);
int open(const char *name, int mode, uint open_options);
int close(void);
int write_row(uchar * buf);
diff --git a/storage/myisam/ha_myisam.cc b/storage/myisam/ha_myisam.cc
index c86459ae0a7..77334b2cfba 100644
--- a/storage/myisam/ha_myisam.cc
+++ b/storage/myisam/ha_myisam.cc
@@ -607,41 +607,7 @@ err:
#endif /* HAVE_REPLICATION */
-bool ha_myisam::check_if_locking_is_allowed(uint sql_command,
- ulong type, TABLE *table,
- uint count, uint current,
- uint *system_count,
- bool called_by_privileged_thread)
-{
- /*
- To be able to open and lock for reading system tables like 'mysql.proc',
- when we already have some tables opened and locked, and avoid deadlocks
- we have to disallow write-locking of these tables with any other tables.
- */
- if (table->s->system_table &&
- table->reginfo.lock_type >= TL_WRITE_ALLOW_WRITE)
- (*system_count)++;
-
- /* 'current' is an index, that's why '<=' below. */
- if (*system_count > 0 && *system_count <= current)
- {
- my_error(ER_WRONG_LOCK_OF_SYSTEM_TABLE, MYF(0));
- return FALSE;
- }
-
- /*
- Deny locking of the log tables, which is incompatible with
- concurrent insert. Unless called from a logger THD (general_log_thd
- or slow_log_thd) or by a privileged thread.
- */
- if (!called_by_privileged_thread)
- return check_if_log_table_locking_is_allowed(sql_command, type, table);
-
- return TRUE;
-}
-
- /* Name is here without an extension */
-
+/* Name is here without an extension */
int ha_myisam::open(const char *name, int mode, uint test_if_locked)
{
MI_KEYDEF *keyinfo;
diff --git a/storage/myisam/ha_myisam.h b/storage/myisam/ha_myisam.h
index 024675075c2..635f314b3da 100644
--- a/storage/myisam/ha_myisam.h
+++ b/storage/myisam/ha_myisam.h
@@ -60,11 +60,6 @@ class ha_myisam: public handler
uint max_supported_key_part_length() const { return MI_MAX_KEY_LENGTH; }
uint checksum() const;
- virtual bool check_if_locking_is_allowed(uint sql_command,
- ulong type, TABLE *table,
- uint count, uint current,
- uint *system_count,
- bool called_by_logger_thread);
int open(const char *name, int mode, uint test_if_locked);
int close(void);
int write_row(uchar * buf);