summaryrefslogtreecommitdiff
path: root/sql/sql_class.cc
diff options
context:
space:
mode:
authorunknown <reggie@fedora.(none)>2005-12-30 06:32:33 -0600
committerunknown <reggie@fedora.(none)>2005-12-30 06:32:33 -0600
commit3846dff8a8f5525b8df86c30aca0f932d4cad347 (patch)
treee67b51ee8c579260bd1b163a095606b9636865c4 /sql/sql_class.cc
parent565e729e384f268a042c9a9e72f85518b10b0dce (diff)
downloadmariadb-git-3846dff8a8f5525b8df86c30aca0f932d4cad347.tar.gz
some casts and simple fixes to fix compile errors in Visual 2005
sql/log_event.cc: some casts to make Visual 2005 happy sql/log_event.h: actually return a bool expression instead of assuming a pointer expression is boolean sql/sql_class.cc: some casts to make Visual 2005 happy sql/handler.cc: actually return 0 as the function docs say
Diffstat (limited to 'sql/sql_class.cc')
-rw-r--r--sql/sql_class.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc
index 7c6f61d6edc..0eb1e04cafb 100644
--- a/sql/sql_class.cc
+++ b/sql/sql_class.cc
@@ -2322,7 +2322,7 @@ my_size_t THD::pack_row(TABLE *table, MY_BITMAP const* cols, byte *row_data,
for (int i= 0 ; field ; i++, p_field++, field= *p_field)
{
if (bitmap_is_set(cols,i))
- ptr= field->pack(ptr, field->ptr + offset);
+ ptr= (byte*)field->pack(ptr, field->ptr + offset);
}
/*
@@ -2398,7 +2398,7 @@ int THD::binlog_update_row(TABLE* table, bool is_trans,
}
else
{
- if (unlikely(!(row_data= my_multi_malloc(MYF(MY_WME),
+ if (unlikely(!(row_data= (byte*)my_multi_malloc(MYF(MY_WME),
&before_row, before_maxlen,
&after_row, after_maxlen,
NULL))))
@@ -2420,7 +2420,7 @@ int THD::binlog_update_row(TABLE* table, bool is_trans,
if (!table->write_row_record)
{
/* add_row_data copies row_data to internal buffer */
- my_free(row_data, MYF(MY_WME));
+ my_free((gptr)row_data, MYF(MY_WME));
}
return error;
@@ -2439,7 +2439,7 @@ int THD::binlog_delete_row(TABLE* table, bool is_trans,
bool error= 0;
my_size_t const max_len= max_row_length(table, record);
byte *row_data= table->write_row_record;
- if (!row_data && unlikely(!(row_data= my_malloc(max_len, MYF(MY_WME)))))
+ if (!row_data && unlikely(!(row_data= (byte*)my_malloc(max_len, MYF(MY_WME)))))
return HA_ERR_OUT_OF_MEM;
my_size_t const len= pack_row(table, cols, row_data, record);
@@ -2451,7 +2451,7 @@ int THD::binlog_delete_row(TABLE* table, bool is_trans,
/* add_row_data copies row_data */
if (table->write_row_record == 0)
- my_free(row_data, MYF(MY_WME));
+ my_free((gptr)row_data, MYF(MY_WME));
return error;
}