summaryrefslogtreecommitdiff
path: root/sql/ha_partition.cc
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2014-09-16 14:03:17 +0200
committerSergei Golubchik <sergii@pisem.net>2014-09-16 14:03:17 +0200
commit7e29c1b53968914f42300a7f628088b99601f4db (patch)
treed9b55e33bd83a02251cd8a3fe560ef149c7b21ca /sql/ha_partition.cc
parent1e3e81a6c9971a56c94086227aa438d133172863 (diff)
parent33656e042dc7e983c9612a011fdef64a8dd40aa1 (diff)
downloadmariadb-git-7e29c1b53968914f42300a7f628088b99601f4db.tar.gz
5.5 merge
Diffstat (limited to 'sql/ha_partition.cc')
-rw-r--r--sql/ha_partition.cc5
1 files changed, 1 insertions, 4 deletions
diff --git a/sql/ha_partition.cc b/sql/ha_partition.cc
index f503b2f54e5..4420f2c7e07 100644
--- a/sql/ha_partition.cc
+++ b/sql/ha_partition.cc
@@ -8589,8 +8589,7 @@ void ha_partition::get_auto_increment(ulonglong offset, ulonglong increment,
ulonglong first_value_part, max_first_value;
handler **file= m_file;
first_value_part= max_first_value= *first_value;
- /* Must lock and find highest value among all partitions. */
- lock_auto_increment();
+ /* Must find highest value among all partitions. */
do
{
/* Only nb_desired_values = 1 makes sense */
@@ -8601,7 +8600,6 @@ void ha_partition::get_auto_increment(ulonglong offset, ulonglong increment,
*first_value= first_value_part;
/* log that the error was between table/partition handler */
sql_print_error("Partition failed to reserve auto_increment value");
- unlock_auto_increment();
DBUG_VOID_RETURN;
}
DBUG_PRINT("info", ("first_value_part: %lu", (ulong) first_value_part));
@@ -8609,7 +8607,6 @@ void ha_partition::get_auto_increment(ulonglong offset, ulonglong increment,
} while (*(++file));
*first_value= max_first_value;
*nb_reserved_values= 1;
- unlock_auto_increment();
}
else
{