[Asterisk-code-review] backtrace: Avoid -Wlogical-not-parentheses. (asterisk[13])

Richard Mudgett asteriskteam at digium.com
Wed Jan 31 07:57:01 CST 2018


Richard Mudgett has posted comments on this change. ( https://gerrit.asterisk.org/8105 )

Change subject: backtrace: Avoid -Wlogical-not-parentheses.
......................................................................


Patch Set 1:

> OK. I am a bit confused about your ‘more’. According to clang (and
 > my book about precedence) your proposal changes the code. clang
 > offers both alternatives as suggestion. So, this was a bug
 > actually?

Yes I think the compiler really found a bug.

bfd_get_section_flags() returns flags and SEC_ALLOC is one of those flags we could test.  According to the comments associated with SEC_ALLOC, the current section is allocated if set.  i.e., It has program code (or constant data) in it.  If not set the section is only debug information.

So the if expression was trying to say: If the bfd section does not have code in it or the section's code contents does not contain the offset address then skip the section.


-- 
To view, visit https://gerrit.asterisk.org/8105
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: comment
Gerrit-Change-Id: I9ec3e144d425a976c02811bd23cd0c533d2eca4e
Gerrit-Change-Number: 8105
Gerrit-PatchSet: 1
Gerrit-Owner: Alexander Traud <pabstraud at compuserve.com>
Gerrit-Reviewer: Alexander Traud <pabstraud at compuserve.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>
Gerrit-Comment-Date: Wed, 31 Jan 2018 13:57:01 +0000
Gerrit-HasComments: No
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180131/cc0a7483/attachment.html>


More information about the asterisk-code-review mailing list