[asterisk-dev] [Code Review] 4533: clang compiler warning: -Wtautological-compare

Matt Jordan reviewboard at asterisk.org
Thu Mar 26 20:14:09 CDT 2015



> On March 26, 2015, 5:13 p.m., Diederik de Groot wrote:
> > /branches/13/channels/pjsip/dialplan_functions.c, line 869
> > <https://reviewboard.asterisk.org/r/4533/diff/1/?file=72956#file72956line869>
> >
> >     len is of type size_t, which is unsigned. It will not be able to hold a value < 0

Rather than opening issues against your review - which indicate that there is some problem with the code change - I would instead put these kinds of descriptions into your description of the code change.

That's helpful as well for when the change is merged - someone has to craft a commit message that describes the code change, and having a well written description that describes each change is almost always better than a terse sentence :-)

As it is, make sure you close out the "issues" so that reviewers know that these aren't actually problems.


- Matt


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/4533/#review14862
-----------------------------------------------------------


On March 26, 2015, 4:50 p.m., Diederik de Groot wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/4533/
> -----------------------------------------------------------
> 
> (Updated March 26, 2015, 4:50 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:-Wtautological-compare
> 
> 
> Diffs
> -----
> 
>   /branches/13/res/res_stasis_recording.c 433444 
>   /branches/13/res/res_stasis_playback.c 433444 
>   /branches/13/res/res_pjsip_exten_state.c 433444 
>   /branches/13/res/ari/resource_channels.c 433444 
>   /branches/13/res/ari/resource_bridges.c 433444 
>   /branches/13/main/udptl.c 433444 
>   /branches/13/main/security_events.c 433444 
>   /branches/13/main/presencestate.c 433444 
>   /branches/13/main/indications.c 433444 
>   /branches/13/main/event.c 433444 
>   /branches/13/main/enum.c 433444 
>   /branches/13/main/cel.c 433444 
>   /branches/13/main/app.c 433444 
>   /branches/13/include/asterisk/cel.h 433444 
>   /branches/13/include/asterisk/app.h 433444 
>   /branches/13/funcs/func_curl.c 433444 
>   /branches/13/channels/pjsip/dialplan_functions.c 433444 
> 
> Diff: https://reviewboard.asterisk.org/r/4533/diff/
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Diederik de Groot
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20150327/77eae16a/attachment-0001.html>


More information about the asterisk-dev mailing list