[asterisk-dev] [Code Review] 4527: clang compiler warning: -Wunused-function
Diederik de Groot
reviewboard at asterisk.org
Thu Mar 26 12:52:37 CDT 2015
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/4527/#review14856
-----------------------------------------------------------
/branches/13/channels/chan_iax2.c
<https://reviewboard.asterisk.org/r/4527/#comment25464>
user_ref function not being used, may/might actually indicate a refcount issue.
Because of the simple nature of these two functions, they could as well be implemented using
#define user_ref(_USER) ao2_ref(_USER, +1)
#define user_unref(_USER) ao2_ref(_USER, -1)
instead. Which would not have generated this unused warning, and after compilation they would both result in the same code (inline).
- Diederik de Groot
On March 26, 2015, 6:47 p.m., Diederik de Groot wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/4527/
> -----------------------------------------------------------
>
> (Updated March 26, 2015, 6:47 p.m.)
>
>
> Review request for Asterisk Developers.
>
>
> Bugs: ASTERISK-24917
> https://issues.asterisk.org/jira/browse/ASTERISK-24917
>
>
> Repository: Asterisk
>
>
> Description
> -------
>
> clang's static analyzer will throw quite a number warnings / errors during compilation, some of which can be very helpfull in finding corner-case bugs\nclang compiler warning:-Wunused-function
>
>
> Diffs
> -----
>
> /branches/13/main/dsp.c 433444
> /branches/13/main/config.c 433444
> /branches/13/channels/chan_iax2.c 433444
>
> Diff: https://reviewboard.asterisk.org/r/4527/diff/
>
>
> Testing
> -------
>
>
> Thanks,
>
> Diederik de Groot
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20150326/c34a8b14/attachment-0001.html>
More information about the asterisk-dev
mailing list