summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorunknown <patg@radha.patg.net>2006-12-21 22:38:54 -0500
committerunknown <patg@radha.patg.net>2006-12-21 22:38:54 -0500
commit0539400a3ec78d8455ce61388f7b0e6ea5d470db (patch)
treebd5232aefa6e8bcc963b48390635fbfb9dc441cf /sql
parentfe9df525cd0b49531b14ff4ce9b51c1d7666f8e1 (diff)
downloadmariadb-git-0539400a3ec78d8455ce61388f7b0e6ea5d470db.tar.gz
WL #3031
* Various windows errors fixed * Increased max key length for federated include/my_time.h: WL #3031 Windows compile errors for some platforms. JBalint helped find this fix. sql/log_event.cc: WL #3031 Windows compile errors on some platforms. explicite casting. sql/sql_servers.cc: WL #3031 Add rwlock init to sql_servers to fix hang on windows. storage/federated/ha_federated.h: WL #3031 Increase max key length to innodb's max (Cisco fix)
Diffstat (limited to 'sql')
-rw-r--r--sql/log_event.cc12
-rw-r--r--sql/sql_servers.cc3
2 files changed, 9 insertions, 6 deletions
diff --git a/sql/log_event.cc b/sql/log_event.cc
index 4bdaadd3371..d4e9b3d9db2 100644
--- a/sql/log_event.cc
+++ b/sql/log_event.cc
@@ -5558,8 +5558,8 @@ unpack_row(RELAY_LOG_INFO *rli,
if (bitmap_is_set(cols, field_ptr - begin_ptr))
{
- DBUG_ASSERT(table->record[0] <= f->ptr);
- DBUG_ASSERT(f->ptr < (table->record[0] + table->s->reclength +
+ DBUG_ASSERT((const char *)table->record[0] <= f->ptr);
+ DBUG_ASSERT(f->ptr < ((const char *)table->record[0] + table->s->reclength +
(f->pack_length_in_rec() == 0)));
DBUG_PRINT("info", ("unpacking column '%s' to 0x%lx", f->field_name,
@@ -6843,8 +6843,8 @@ static int find_and_fetch_row(TABLE *table, byte *key)
trigger false warnings.
*/
#ifndef HAVE_purify
- DBUG_DUMP("table->record[0]", table->record[0], table->s->reclength);
- DBUG_DUMP("table->record[1]", table->record[1], table->s->reclength);
+ DBUG_DUMP("table->record[0]", (const char *)table->record[0], table->s->reclength);
+ DBUG_DUMP("table->record[1]", (const char *)table->record[1], table->s->reclength);
#endif
/*
@@ -6870,8 +6870,8 @@ static int find_and_fetch_row(TABLE *table, byte *key)
trigger false warnings.
*/
#ifndef HAVE_purify
- DBUG_DUMP("table->record[0]", table->record[0], table->s->reclength);
- DBUG_DUMP("table->record[1]", table->record[1], table->s->reclength);
+ DBUG_DUMP("table->record[0]", (const char *)table->record[0], table->s->reclength);
+ DBUG_DUMP("table->record[1]", (const char *)table->record[1], table->s->reclength);
#endif
/*
Below is a minor "optimization". If the key (i.e., key number
diff --git a/sql/sql_servers.cc b/sql/sql_servers.cc
index 397ea88b033..384135c069b 100644
--- a/sql/sql_servers.cc
+++ b/sql/sql_servers.cc
@@ -76,6 +76,9 @@ my_bool servers_init(bool dont_read_servers_table)
if (pthread_mutex_init(&servers_cache_mutex, MY_MUTEX_INIT_FAST))
DBUG_RETURN(1);
+ if (my_rwlock_init(&THR_LOCK_servers, NULL))
+ DBUG_RETURN(1);
+
/* initialise our servers cache */
if (hash_init(&servers_cache, system_charset_info, 32, 0, 0,
(hash_get_key) servers_cache_get_key, 0, 0))