diff options
author | monty@mashka.mysql.fi <> | 2002-12-26 18:26:37 +0200 |
---|---|---|
committer | monty@mashka.mysql.fi <> | 2002-12-26 18:26:37 +0200 |
commit | 3ca695ea0bc5a4cac6feba7aeee9e87fda79afc4 (patch) | |
tree | 52c14204adc0f3d7ef9707add0e6d1da72ed37d8 /sql/ha_innodb.cc | |
parent | 0a5338614a1d4a4edde88c24b55c4879332f7e4d (diff) | |
download | mariadb-git-3ca695ea0bc5a4cac6feba7aeee9e87fda79afc4.tar.gz |
Cut hostnames at HOSTNAME_LENGTH to avoid theoretical hostname overruns
Changed long packat handling to check for packets of length 0xffffff.
This does however break packet handling for older clients.
If you are using packets >= 16M then you need to upgrade client and server
after this patch.
Diffstat (limited to 'sql/ha_innodb.cc')
-rw-r--r-- | sql/ha_innodb.cc | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/sql/ha_innodb.cc b/sql/ha_innodb.cc index dd718f02ba9..b34de8cb831 100644 --- a/sql/ha_innodb.cc +++ b/sql/ha_innodb.cc @@ -1907,12 +1907,9 @@ ha_innobase::write_row( the counter here. */ skip_auto_inc_decr = FALSE; - - if (error == DB_DUPLICATE_KEY) { - ut_a(user_thd->query); - dict_accept(user_thd->query, "REPLACE", - &skip_auto_inc_decr); - } + if (error == DB_DUPLICATE_KEY && + user_thd->lex.sql_command == SQLCOM_REPLACE) + skip_auto_inc_decr= TRUE; if (!skip_auto_inc_decr && incremented_auto_inc_counter && prebuilt->trx->auto_inc_lock) { |