diff options
author | unknown <mskold/marty@mysql.com/quadfish.(none)> | 2007-11-06 10:28:11 +0100 |
---|---|---|
committer | unknown <mskold/marty@mysql.com/quadfish.(none)> | 2007-11-06 10:28:11 +0100 |
commit | 404d52fc97c9021fdab6b9ada2e91e48f0caf9dd (patch) | |
tree | 9cf7bdf157be53bc8e6c9063d40dbccd70c0a37f /sql/ha_ndbcluster.cc | |
parent | f7ee88253a7d4620de3651c3c4d7cb7a3ab3d8ac (diff) | |
download | mariadb-git-404d52fc97c9021fdab6b9ada2e91e48f0caf9dd.tar.gz |
Removed compiler warnings
Diffstat (limited to 'sql/ha_ndbcluster.cc')
-rw-r--r-- | sql/ha_ndbcluster.cc | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc index de6187da70f..d29e9345c11 100644 --- a/sql/ha_ndbcluster.cc +++ b/sql/ha_ndbcluster.cc @@ -4901,7 +4901,7 @@ int ha_ndbcluster::drop_table() ulonglong ha_ndbcluster::get_auto_increment() { - int cache_size; + uint cache_size; Uint64 auto_value; THD *thd= current_thd; Uint64 step= thd->variables.auto_increment_increment; @@ -4915,15 +4915,14 @@ ulonglong ha_ndbcluster::get_auto_increment() /* We guessed too low */ m_rows_to_insert+= m_autoincrement_prefetch; } - int remaining= m_rows_to_insert - m_rows_inserted; - int min_prefetch= + uint remaining= m_rows_to_insert - m_rows_inserted; + uint min_prefetch= (remaining < thd->variables.ndb_autoincrement_prefetch_sz) ? thd->variables.ndb_autoincrement_prefetch_sz : remaining; - cache_size= - (int) ((remaining < m_autoincrement_prefetch) ? - min_prefetch - : remaining); + cache_size= ((remaining < m_autoincrement_prefetch) ? + min_prefetch + : remaining); uint retries= NDB_AUTO_INCREMENT_RETRIES; int retry_sleep= 30; /* 30 milliseconds, transaction */ for (;;) |