summaryrefslogtreecommitdiff
path: root/sql/key.cc
diff options
context:
space:
mode:
Diffstat (limited to 'sql/key.cc')
-rw-r--r--sql/key.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/sql/key.cc b/sql/key.cc
index fa09a0a6d44..84669808b92 100644
--- a/sql/key.cc
+++ b/sql/key.cc
@@ -193,8 +193,9 @@ int key_cmp(TABLE *table,const byte *key,uint idx,uint key_length)
FIELDFLAG_PACK)))
{
/* BAR TODO: I'm not sure this should be system_charset_info */
- if (my_sortcmp(system_charset_info,(char*) key,
- (char*) table->record[0]+key_part->offset,length))
+ if (my_strnncoll(system_charset_info,
+ (const uchar*) key, length,
+ (const uchar*) table->record[0]+key_part->offset,length))
return 1;
}
else if (memcmp(key,table->record[0]+key_part->offset,length))