Bug #3296 SET character_set_results=NULL crashes server

Submitted: 25 Mar 2004 16:36 Modified: 30 Mar 2004 23:17
Reporter: Paul DuBois Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:4.1.2 OS:Linux (Linux)
Assigned to: Oleksandr Byelkin CPU Architecture:Any

[25 Mar 2004 16:36] Paul DuBois
Description:
On Mac OS X, I can set character_set_results to NULL
and retrieve the value:

mysql> set character_set_results=null;
Query OK, 0 rows affected (0.00 sec)

mysql> select @@character_set_results;
+-------------------------+
| @@character_set_results |
+-------------------------+
| NULL                    |
+-------------------------+
1 row in set (0.00 sec)

But on Red Hat or Gentoo Linux, the server crashes:

mysql> set character_set_results=null;
Query OK, 0 rows affected (0.00 sec)

mysql> select @@character_set_results;
ERROR 2013 (HY000): Lost connection to MySQL server during query

How to repeat:
See above.
[25 Mar 2004 17:36] Paul DuBois
Additional information: The crash is specific to the use of SELECT @@var_name
form.  Retrieving the value using SHOW VARIABLES works fine:

mysql> set character_set_results=null;
Query OK, 0 rows affected (0.00 sec)

mysql> show variables like 'character\_set\_results';
+-----------------------+-------+
| Variable_name         | Value |
+-----------------------+-------+
| character_set_results | NULL  |
+-----------------------+-------+
1 row in set (0.00 sec)
[25 Mar 2004 18:23] MySQL Verification Team
Paul I tested on Windows and Suse 9.0 with a server built with 1 day older BK
4.1 tree without to crash.
[30 Mar 2004 9:28] MySQL Verification Team
Sorry Paul,

But works for me fine too.
[30 Mar 2004 9:49] Paul DuBois
Sinisa,

What kind of system did you try it on? I already indicated below
that it happens only on some systems.

I'm disappointed you declare it not a bug, given that it's a trivial
way to crash the server.  If you tell me what information would be
helpful, I'll try to provide it.
[30 Mar 2004 10:02] MySQL Verification Team
This was tested on both Linux and Windows.
[30 Mar 2004 12:44] Oleksandr Byelkin
ChangeSet 
  1.1746 04/03/30 23:38:56 bell@sanja.is.com.ua +3 -0 
  null processing for character_set_results (BUG#3296)
[30 Mar 2004 23:17] Oleksandr Byelkin
Thank you for bugreport. Patch for this bug is pushed to our internal source 
repository and will be present in next release of server 4.1

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

Page generated in 0.057 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.