[asterisk-dev] [Code Review] 4526: clang compiler warning: -Wunused-value -Wunused-variable -Wunused-const-variable

Diederik de Groot reviewboard at asterisk.org
Fri Mar 27 06:09:50 CDT 2015


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

(Updated March 27, 2015, 12:09 p.m.)


Review request for Asterisk Developers.


Bugs: ASTERISK-24917
    https://issues.asterisk.org/jira/browse/ASTERISK-24917


Repository: Asterisk


Description (updated)
-------

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

clang compiler warning:-Wunused-value -Wunused-variable -Wunused-const-variable

Changes:
apps/app_queue.c: removed unused qpm_cmd_usage[], qum_cmd_usage[], qsmp_cmd_usage[]
cel/cel_sqlite3_custom.c: removed unused name[] = "cel_sqlite3_custom"
channels/chan_pjsip.c: removed unused desc[] = "PJSIP Channel"
codecs/gsm/src/gsm_create.c: removed unused ident[] = "$Header$"
funcs/func_env.c:729: Fixed ast_str_append_substr. Needs to be reviewed by code owner.
main/config.c: inline functions have to be static for clang to grok them
main/editline/np/strlcat.c: removed unused rcsid = "$OpenBSD: strlcat.c,v 1.2 1999/06/17 16:28:58 millert Exp $"
main/editline/np/strlcpy.c: removed unused rcsid = "$OpenBSD: strlcpy.c,v 1.4 1999/05/01 18:56:41 millert Exp $"
main/features.c: removed unused channel_app_data_datastore struct
main/security_events.c: removed unused TIMESTAMP_STR_LEN
utils/conf2ael.c: removed unused cfextension_states
utils/extconf.c: removed unused cfextension_states


Diffs
-----

  /branches/13/utils/extconf.c 433444 
  /branches/13/utils/conf2ael.c 433444 
  /branches/13/main/security_events.c 433444 
  /branches/13/main/features.c 433444 
  /branches/13/main/editline/np/strlcpy.c 433444 
  /branches/13/main/editline/np/strlcat.c 433444 
  /branches/13/main/config.c 433470 
  /branches/13/funcs/func_env.c 433444 
  /branches/13/codecs/gsm/src/gsm_create.c 433444 
  /branches/13/channels/chan_pjsip.c 433444 
  /branches/13/cel/cel_sqlite3_custom.c 433444 
  /branches/13/apps/app_queue.c 433444 

Diff: https://reviewboard.asterisk.org/r/4526/diff/


Testing
-------


Thanks,

Diederik de Groot

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


More information about the asterisk-dev mailing list