The default bug view has changed. See this FAQ.

initializer reorder warning + suggested brace (debug code)

RESOLVED FIXED in mozilla15

Status

()

Core
Disability Access APIs
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: hub, Assigned: hub)

Tracking

Trunk
mozilla15
x86_64
Linux
Points:
---
Bug Flags:
in-testsuite -

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
When building m-c, there are some initializer reorder warning and suggested brace (debug code) warnings.

Attaching patch to fix these.
(Assignee)

Comment 1

5 years ago
Created attachment 622100 [details] [diff] [review]
Fix some warnings. r=
(Assignee)

Comment 2

5 years ago
Comment on attachment 622100 [details] [diff] [review]
Fix some warnings. r=

Review of attachment 622100 [details] [diff] [review]:
-----------------------------------------------------------------

::: accessible/src/base/TextAttrs.h
@@ +118,5 @@
>  private:
>    nsAccessible* mOffsetAcc;
>    nsHyperTextAccessible* mHyperTextAcc;
> +  PRInt32 mOffsetAccIdx;
> +  bool mIncludeDefAttrs;

These two lines, I removed a spurious ^M left by a Windows editor.
Attachment #622100 - Flags: review?(dbolter)
Comment on attachment 622100 [details] [diff] [review]
Fix some warnings. r=

Review of attachment 622100 [details] [diff] [review]:
-----------------------------------------------------------------

r=me fine with me.

::: accessible/src/atk/ApplicationAccessibleWrap.cpp
@@ +637,2 @@
>              MAI_LOG_DEBUG(("Fail to load lib: %s\n", sAtkBridge.libName));
> +        }

Ah right... multi statement macro danger.
Attachment #622100 - Flags: review?(dbolter) → review+
Comment on attachment 622100 [details] [diff] [review]
Fix some warnings. r=

>         if (NS_SUCCEEDED(rv)) {
>             // init atk-bridge
>             (*sAtkBridge.init)();
>         }
>-        else
>+        else {
>             MAI_LOG_DEBUG(("Fail to load lib: %s\n", sAtkBridge.libName));
>+        }

I tend to think the better fix is to make sure macros like this always expand to a statement

Also always use } else {
(Assignee)

Comment 5

5 years ago
I'll fix the braces :-)
(Assignee)

Comment 6

5 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/e40ee1b66d6d
Assignee: nobody → hub
Target Milestone: --- → mozilla15
https://hg.mozilla.org/mozilla-central/rev/e40ee1b66d6d
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.