summaryrefslogtreecommitdiff
path: root/innobase/row/row0ins.c
diff options
context:
space:
mode:
Diffstat (limited to 'innobase/row/row0ins.c')
-rw-r--r--innobase/row/row0ins.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/innobase/row/row0ins.c b/innobase/row/row0ins.c
index c5d90524fdd..7b0beb9d183 100644
--- a/innobase/row/row0ins.c
+++ b/innobase/row/row0ins.c
@@ -2019,16 +2019,12 @@ row_ins_index_entry_set_vals(
if (ind_field->prefix_len > 0
&& dfield_get_len(row_field) != UNIV_SQL_NULL) {
- /* For prefix keys get the storage length
- for the prefix_len characters. */
-
cur_type = dict_col_get_type(
dict_field_get_col(ind_field));
- field->len = innobase_get_at_most_n_mbchars(
- dtype_get_charset_coll(cur_type->prtype),
- ind_field->prefix_len,
- dfield_get_len(row_field),row_field->data);
+ field->len = dtype_get_at_most_n_mbchars(cur_type,
+ ind_field->prefix_len,
+ dfield_get_len(row_field), row_field->data);
} else {
field->len = row_field->len;
}