| Bug #69172 | Wasted work in method Config::illegal_change() | ||
|---|---|---|---|
| Submitted: | 8 May 2013 3:34 | Modified: | 10 Jun 2013 14:04 |
| Reporter: | Po-Chun Chang (OCA) | Email Updates: | |
| Status: | Closed | Impact on me: | |
| Category: | MySQL Server: Command-line Clients | Severity: | S5 (Performance) |
| Version: | 5.6, 5.7 | OS: | Any |
| Assigned to: | CPU Architecture: | Any | |
| Tags: | patch, performance | ||
[8 May 2013 3:35]
Po-Chun Chang
Suggested patch
Attachment: patch.diff (text/plain), 419 bytes.
[8 May 2013 6:41]
MySQL Verification Team
Thank you for the bug report and contribution.
[10 Jun 2013 14:04]
Magnus BlÄudd
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 bug fix. More information about accessing the source trees is available at
http://dev.mysql.com/doc/en/installing-source.html
Fixed from MySQL Cluster 7.0.39 and upwards
[17 Jun 2013 11:39]
Jon Stephens
For documentation, see BUG#69393.

Description: The problem appears in version 5.6 and in the latest revision 5216 in version 5.7. I have attached a simple one-line patch (patch.diff) that fixes it. This problem is similar to the already verified MySQL #69117. In method "Config::illegal_change()" in Config.cpp, the loop on line 746 should break immediately after "illegal" is set to "true". All the iterations after "illegal" is set to "true" do not perform any useful work, at best they just set "illegal" again to "true". How to repeat: Once Config::illegal_change() is executed. Suggested fix: === modified file 'storage/ndb/src/mgmsrv/Config.cpp' --- storage/ndb/src/mgmsrv/Config.cpp 2013-02-26 05:45:28 +0000 +++ storage/ndb/src/mgmsrv/Config.cpp 2013-05-08 03:32:56 +0000 @@ -751,8 +751,10 @@ Uint32 type; require(what->get("Type", &type)); - if (type == DT_ILLEGAL_CHANGE) + if (type == DT_ILLEGAL_CHANGE) { illegal= true; + break; + } } } return illegal;