Bug #5397 Crash with varchar binary and LIKE

Submitted: 3 Sep 2004 19:24 Modified: 6 Sep 2004 13:37
Reporter: Dean Ellis Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S1 (Critical)
Version:4.1.5-gamma bk 1.1993 OS:
Assigned to: Alexander Barkov CPU Architecture:Any

[3 Sep 2004 19:24] Dean Ellis
Description:
VARCHAR() BINARY with LIKE crashes mysqld.

How to repeat:
DROP TABLE IF EXISTS t1;
CREATE TABLE t1 ( a varchar(32) BINARY) CHARACTER SET = utf8;
INSERT INTO t1 VALUES ('test');
SELECT a FROM t1 WHERE a LIKE '%te';
DROP TABLE t1;

Stack trace was:

0x816719d handle_segfault + 647
0xffffe420 _end + -139848464
0x8659721 _end + 1034225
0x811d24b Item_func_like::val_int() + 251
0x81a6837 make_join_select(JOIN*, SQL_SELECT*, Item*) + 105
0x81a0864 JOIN::optimize() + 878
0x81a313a mysql_select(THD*, Item***, st_table_list*, unsigned int, List<Item>&, Item*, unsigned int, st_order*, st_order*, Item*, st_ord + 102
0x819fd54 handle_select(THD*, st_lex*, select_result*) + 256
0x8179b2e mysql_execute_command(THD*) + 884
0x817f475 mysql_parse(THD*, char*, unsigned int) + 197
0x8178605 dispatch_command(enum_server_command, THD*, char*, unsigned int) + 1033
0x81781af do_command(THD*) + 147
0x8177967 handle_one_connection + 851
0x40175a1b _end + 935430891
0x4034c27a _end + 937358154

Suggested fix:
n/a
[6 Sep 2004 13:37] Alexander Barkov
Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.

If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.060 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.