Bug #29878 | Garbage data generation when executing SESSION_USER() on a slave. | ||
---|---|---|---|
Submitted: | 18 Jul 2007 18:40 | Modified: | 6 Aug 2007 17:20 |
Reporter: | Dave Costantino | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Replication | Severity: | S2 (Serious) |
Version: | 5.0.30, 5.0 BK, 5.1 BK | OS: | Any |
Assigned to: | Alexey Botchkov | CPU Architecture: | Any |
[18 Jul 2007 18:40]
Dave Costantino
[18 Jul 2007 22:25]
Sveta Smirnova
Thank you for the report. Verified as described. Version 4.1 returns different result: select * from test_rep; id data 1
[25 Jul 2007 11:58]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/31540 ChangeSet@1.2476, 2007-07-25 15:56:55+05:00, holyfoot@mysql.com +5 -0 Bug #29878 Garbage data generation when executing SESSION_USER() on a slave. Item_func_user doesn't calculate anything in it's val_str() method, just returns saved str_value. Though Item::save_in_field method can destroy str_value, relying on val_str() return. As a result we get the garbage stored in field. We cannot use Item::save_in_field implementation for Item_func_user, reimplement it in simpler way.
[27 Jul 2007 13:16]
Alexander Barkov
ok to push
[27 Jul 2007 14:43]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/31710 ChangeSet@1.2476, 2007-07-27 18:42:25+05:00, holyfoot@mysql.com +5 -0 Bug #29878 Garbage data generation when executing SESSION_USER() on a slave. Item_func_user doesn't calculate anything in it's val_str() method, just returns saved str_value. Though Item::save_in_field method can destroy str_value, relying on val_str() return. As a result we get the garbage stored in field. We cannot use Item::save_in_field implementation for Item_func_user, reimplement it in simpler way.
[2 Aug 2007 19:11]
Bugs System
Pushed into 5.1.21-beta
[2 Aug 2007 19:14]
Bugs System
Pushed into 5.0.48
[6 Aug 2007 17:20]
Paul DuBois
Noted in 5.0.48, 5.1.21 changelogs. SESSION_USER() returned garbage data (rather than the correct value of the empty string) when executed by a slave SQL thread.