User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:18.0) Gecko/20100101 Firefox/18.0 (Beta/Release) Build ID: 20130116073211 Steps to reproduce: The problem appears in changeset 138350:18467a85acf6. I have attached a simple one-line patch that fixes it. In method main() in xpcom/tests/TestTextFormatter.cpp, the loop on line 32 should break immediately after "test_ok" is set to "false". All the iterations after "test_ok" is set to "false" do not perform any useful work, at best they just set "test_ok" again to "false". Expected results: Break loop after "test_ok" is set to "false".
Component: Untriaged → XPCOM
Product: Firefox → Core
Comment on attachment 785389 [details] [diff] [review] 898691.patch While we're here, could you please brace the for loop?
Comment on attachment 785419 [details] [diff] [review] 898691-1.patch Looks good to me. Thanks for the patch! The only other thing you need to do is to change the patch description, and then set checkin-needed in the bug's keyword field. Then someone will check this patch in within the next few days. > Bug 898691 (rev #1) - Break loop after "test_ok" is set to "false". Also brace the for loop. Please remove "(rev #1)" and add "r=jlebar" at the end. Also, we try to have patch descriptions say why the patch is doing something; that's more important than describing every little thing we changed, since you can always look at the diff for that. Something like "Avoid wasted work in TestTextFormatter.cpp" would be good, IMO.
Attachment #785419 - Flags: review?(justin.lebar+bug) → review+
Assignee: nobody → pchang9
Status: UNCONFIRMED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla26
You need to log in before you can comment on or make changes to this bug.