[asterisk-bugs] [JIRA] (ASTERISK-27793) cppcheck identifies redundant "if"

Alexander Anikin (JIRA) noreply at issues.asterisk.org
Tue Apr 17 06:32:50 CDT 2018


    [ https://issues.asterisk.org/jira/browse/ASTERISK-27793?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=243040#comment-243040 ] 

Alexander Anikin edited comment on ASTERISK-27793 at 4/17/18 6:32 AM:
----------------------------------------------------------------------

More things to be solved:

ooh323c/src/context.c:168]: (warning) Possible null pointer dereference: pctxt
[ooh323c/src/memheap.c:626]: (warning) Possible null pointer dereference: pElem
[ooh323c/src/memheap.c:689]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:710]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:823]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:1065] -> [ooh323c/src/memheap.c:1067]: (warning) Either the condition 'ppMemHeap!=0' is redundant or there is possible null pointer dereference: ppMemHeap.



was (Author: may213):
More things to be solved:

ooh323c/src/context.c:168]: (warning) Possible null pointer dereference: pctxt
[ooh323c/src/memheap.c:626]: (warning) Possible null pointer dereference: pElem
[ooh323c/src/memheap.c:689]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:710]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:823]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:1065] -> [ooh323c/src/memheap.c:1067]: (warning) Either the condition 'ppMemHeap!=0' is redundant or there is possible null pointer dereference: ppMemHeap.
[ooh323c/src/context.c:168]: (warning) Possible null pointer dereference: pctxt
[ooh323c/src/memheap.c:626]: (warning) Possible null pointer dereference: pElem
[ooh323c/src/memheap.c:689]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:710]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:823]: (warning) Possible null pointer dereference: pNextElem
[ooh323c/src/memheap.c:1065] -> [ooh323c/src/memheap.c:1067]: (warning) Either the condition 'ppMemHeap!=0' is redundant or there is possible null pointer dereference: ppMemHeap.

> cppcheck identifies redundant "if"
> ----------------------------------
>
>                 Key: ASTERISK-27793
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-27793
>             Project: Asterisk
>          Issue Type: Improvement
>      Security Level: None
>          Components: Addons/chan_ooh323
>    Affects Versions: 15.3.0
>            Reporter: Ilya Shipitsin
>            Assignee: Ilya Shipitsin
>            Severity: Trivial
>              Labels: patch, pjsip
>         Attachments: 0001-clean-cppcheck-warning.patch, ASTERISK-27793.patch
>
>
> there's already if(dfr), no need for one more



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list