summaryrefslogtreecommitdiff
path: root/sql/sql_parse.cc
diff options
context:
space:
mode:
authorunknown <guilhem@mysql.com>2004-11-17 16:41:30 +0100
committerunknown <guilhem@mysql.com>2004-11-17 16:41:30 +0100
commitab51882b772b92876de8295ee6d0a09bf085c749 (patch)
treef6bb7203b6b4d3100aea30e5c3ad49d387ce1fa5 /sql/sql_parse.cc
parent3a301ac1f8466eee0941344729a9ba3521da36a7 (diff)
downloadmariadb-git-ab51882b772b92876de8295ee6d0a09bf085c749.tar.gz
Fixes for compilation errors in Windows (casts from uint32* to uint*) in repl and charset code.
Moving the part of user_var.test using UCS2 to ctype_ucs.test mysql-test/r/ctype_ucs.result: result update mysql-test/r/user_var.result: result update mysql-test/t/ctype_ucs.test: importing test piece from user_var.test mysql-test/t/user_var.test: using UCS2 in this test fails on non-USC2-capable binaries, so let's move this piece to ctype_ucs.test. sql/slave.cc: changing arg type to uint32* (as what is used in this arg is &thd->db_length which is uint32*) sql/slave.h: changing arg type to uint32* sql/sql_parse.cc: changing arg types to uint32, as what is used in these args is a create_field::length which is uint32.
Diffstat (limited to 'sql/sql_parse.cc')
-rw-r--r--sql/sql_parse.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/sql_parse.cc b/sql/sql_parse.cc
index 7420f9de100..e066e447345 100644
--- a/sql/sql_parse.cc
+++ b/sql/sql_parse.cc
@@ -4123,7 +4123,7 @@ bool mysql_test_parse_for_slave(THD *thd, char *inBuf, uint length)
- SET uses tot_length.
*/
void calculate_interval_lengths(THD *thd, TYPELIB *interval,
- uint *max_length, uint *tot_length)
+ uint32 *max_length, uint32 *tot_length)
{
const char **pos;
uint *len;
@@ -4135,7 +4135,7 @@ void calculate_interval_lengths(THD *thd, TYPELIB *interval,
*len= (uint) strip_sp((char*) *pos);
uint length= cs->cset->numchars(cs, *pos, *pos + *len);
*tot_length+= length;
- set_if_bigger(*max_length, length);
+ set_if_bigger(*max_length, (uint32)length);
}
}
@@ -4454,7 +4454,7 @@ bool add_field_to_list(THD *thd, char *field_name, enum_field_types type,
if (new_field->pack_length > 4)
new_field->pack_length=8;
new_field->interval=interval;
- uint dummy_max_length;
+ uint32 dummy_max_length;
calculate_interval_lengths(thd, interval,
&dummy_max_length, &new_field->length);
new_field->length+= (interval->count - 1);
@@ -4484,7 +4484,7 @@ bool add_field_to_list(THD *thd, char *field_name, enum_field_types type,
new_field->interval=interval;
new_field->pack_length=interval->count < 256 ? 1 : 2; // Should be safe
- uint dummy_tot_length;
+ uint32 dummy_tot_length;
calculate_interval_lengths(thd, interval,
&new_field->length, &dummy_tot_length);
set_if_smaller(new_field->length,MAX_FIELD_WIDTH-1);