summaryrefslogtreecommitdiff
path: root/sql/field_conv.cc
diff options
context:
space:
mode:
authorunknown <bar@mysql.com>2004-08-19 11:59:33 +0500
committerunknown <bar@mysql.com>2004-08-19 11:59:33 +0500
commit0281941158ba4c7588b89f9f1bd611d8d42863df (patch)
tree9747318c80887ffa3c93f999b16dee054c87c437 /sql/field_conv.cc
parentf9b8ffc2ae5d9f86ea9eaea403b9afda58e43d6a (diff)
downloadmariadb-git-0281941158ba4c7588b89f9f1bd611d8d42863df.tar.gz
Bug#5081: UCS2 fields are filled with '0x2020' after extending field length
Diffstat (limited to 'sql/field_conv.cc')
-rw-r--r--sql/field_conv.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/field_conv.cc b/sql/field_conv.cc
index e98068ef974..d7993939092 100644
--- a/sql/field_conv.cc
+++ b/sql/field_conv.cc
@@ -340,8 +340,10 @@ static void do_cut_string(Copy_field *copy)
static void do_expand_string(Copy_field *copy)
{
+ CHARSET_INFO *cs= copy->from_field->charset();
memcpy(copy->to_ptr,copy->from_ptr,copy->from_length);
- bfill(copy->to_ptr+copy->from_length,copy->to_length-copy->from_length,' ');
+ cs->cset->fill(cs, copy->to_ptr+copy->from_length,
+ copy->to_length-copy->from_length, ' ');
}
static void do_varstring(Copy_field *copy)