[svn-commits] russell: trunk r48303 - in /trunk: main/ pbx/

svn-commits at lists.digium.com svn-commits at lists.digium.com
Wed Dec 6 00:28:57 MST 2006


Author: russell
Date: Wed Dec  6 01:28:56 2006
New Revision: 48303

URL: http://svn.digium.com/view/asterisk?view=rev&rev=48303
Log:
Staticize one, and Constify a bunch of usage strings for CLI commands.

Modified:
    trunk/main/channel.c
    trunk/main/db.c
    trunk/main/file.c
    trunk/main/frame.c
    trunk/main/rtp.c
    trunk/main/translate.c
    trunk/main/udptl.c
    trunk/pbx/pbx_dundi.c

Modified: trunk/main/channel.c
URL: http://svn.digium.com/view/asterisk/trunk/main/channel.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/channel.c (original)
+++ trunk/main/channel.c Wed Dec  6 01:28:56 2006
@@ -289,11 +289,11 @@
 	return ret;
 }
 
-static char show_channeltypes_usage[] =
+static const char show_channeltypes_usage[] =
 "Usage: core show channeltypes\n"
 "       Lists available channel types registered in your Asterisk server.\n";
 
-static char show_channeltype_usage[] =
+static const char show_channeltype_usage[] =
 "Usage: core show channeltype <name>\n"
 "	Show details about the specified channel type, <name>.\n";
 

Modified: trunk/main/db.c
URL: http://svn.digium.com/view/asterisk/trunk/main/db.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/db.c (original)
+++ trunk/main/db.c Wed Dec  6 01:28:56 2006
@@ -467,31 +467,31 @@
 	}
 }
 
-static char database_show_usage[] =
+static const char database_show_usage[] =
 "Usage: database show [family [keytree]]\n"
 "       Shows Asterisk database contents, optionally restricted\n"
 "to a given family, or family and keytree.\n";
 
-static char database_showkey_usage[] =
+static const char database_showkey_usage[] =
 "Usage: database showkey <keytree>\n"
 "       Shows Asterisk database contents, restricted to a given key.\n";
 
-static char database_put_usage[] =
+static const char database_put_usage[] =
 "Usage: database put <family> <key> <value>\n"
 "       Adds or updates an entry in the Asterisk database for\n"
 "a given family, key, and value.\n";
 
-static char database_get_usage[] =
+static const char database_get_usage[] =
 "Usage: database get <family> <key>\n"
 "       Retrieves an entry in the Asterisk database for a given\n"
 "family and key.\n";
 
-static char database_del_usage[] =
+static const char database_del_usage[] =
 "Usage: database del <family> <key>\n"
 "       Deletes an entry in the Asterisk database for a given\n"
 "family and key.\n";
 
-static char database_deltree_usage[] =
+static const char database_deltree_usage[] =
 "Usage: database deltree <family> [keytree]\n"
 "       Deletes a family or specific keytree within a family\n"
 "in the Asterisk database.\n";

Modified: trunk/main/file.c
URL: http://svn.digium.com/view/asterisk/trunk/main/file.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/file.c (original)
+++ trunk/main/file.c Wed Dec  6 01:28:56 2006
@@ -1156,7 +1156,7 @@
 #undef FORMAT2
 }
 
-char show_file_formats_usage[] = 
+static const char show_file_formats_usage[] = 
 "Usage: core show file formats\n"
 "       Displays currently registered file formats (if any)\n";
 

Modified: trunk/main/frame.c
URL: http://svn.digium.com/view/asterisk/trunk/main/frame.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/frame.c (original)
+++ trunk/main/frame.c Wed Dec  6 01:28:56 2006
@@ -648,7 +648,7 @@
 		return RESULT_SUCCESS;
 }
 
-static char frame_show_codecs_usage[] =
+static const char frame_show_codecs_usage[] =
 "Usage: core show codecs [audio|video|image]\n"
 "       Displays codec mapping\n";
 
@@ -877,7 +877,7 @@
 	return RESULT_SUCCESS;
 }
 
-static char frame_stats_usage[] =
+static const char frame_stats_usage[] =
 "Usage: core show frame stats\n"
 "       Displays debugging statistics from framer\n";
 #endif

Modified: trunk/main/rtp.c
URL: http://svn.digium.com/view/asterisk/trunk/main/rtp.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/rtp.c (original)
+++ trunk/main/rtp.c Wed Dec  6 01:28:56 2006
@@ -3412,35 +3412,35 @@
 	return RESULT_SUCCESS;
 }
 
-static char debug_usage[] =
+static const char debug_usage[] =
   "Usage: rtp debug [ip host[:port]]\n"
   "       Enable dumping of all RTP packets to and from host.\n";
 
-static char no_debug_usage[] =
+static const char no_debug_usage[] =
   "Usage: rtp debug off\n"
   "       Disable all RTP debugging\n";
 
-static char stun_debug_usage[] =
+static const char stun_debug_usage[] =
   "Usage: stun debug\n"
   "       Enable STUN (Simple Traversal of UDP through NATs) debugging\n";
 
-static char stun_no_debug_usage[] =
+static const char stun_no_debug_usage[] =
   "Usage: stun debug off\n"
   "       Disable STUN debugging\n";
 
-static char rtcp_debug_usage[] =
+static const char rtcp_debug_usage[] =
   "Usage: rtcp debug [ip host[:port]]\n"
   "       Enable dumping of all RTCP packets to and from host.\n";
   
-static char rtcp_no_debug_usage[] =
+static const char rtcp_no_debug_usage[] =
   "Usage: rtcp debug off\n"
   "       Disable all RTCP debugging\n";
 
-static char rtcp_stats_usage[] =
+static const char rtcp_stats_usage[] =
   "Usage: rtcp stats\n"
   "       Enable dumping of RTCP stats.\n";
   
-static char rtcp_no_stats_usage[] =
+static const char rtcp_no_stats_usage[] =
   "Usage: rtcp stats off\n"
   "       Disable all RTCP stats\n";
 

Modified: trunk/main/translate.c
URL: http://svn.digium.com/view/asterisk/trunk/main/translate.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/translate.c (original)
+++ trunk/main/translate.c Wed Dec  6 01:28:56 2006
@@ -558,7 +558,7 @@
 	return RESULT_SUCCESS;
 }
 
-static char show_trans_usage[] =
+static const char show_trans_usage[] =
 "Usage: core show translation [recalc] [<recalc seconds>]\n"
 "       Displays known codec translators and the cost associated\n"
 "with each conversion.  If the argument 'recalc' is supplied along\n"

Modified: trunk/main/udptl.c
URL: http://svn.digium.com/view/asterisk/trunk/main/udptl.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/main/udptl.c (original)
+++ trunk/main/udptl.c Wed Dec  6 01:28:56 2006
@@ -1153,11 +1153,11 @@
 	return RESULT_SUCCESS;
 }
 
-static char debug_usage[] =
+static const char debug_usage[] =
   "Usage: udptl debug [ip host[:port]]\n"
   "       Enable dumping of all UDPTL packets to and from host.\n";
 
-static char nodebug_usage[] =
+static const char nodebug_usage[] =
   "Usage: udptl debug off\n"
   "       Disable all UDPTL debugging\n";
 

Modified: trunk/pbx/pbx_dundi.c
URL: http://svn.digium.com/view/asterisk/trunk/pbx/pbx_dundi.c?view=diff&rev=48303&r1=48302&r2=48303
==============================================================================
--- trunk/pbx/pbx_dundi.c (original)
+++ trunk/pbx/pbx_dundi.c Wed Dec  6 01:28:56 2006
@@ -2631,71 +2631,71 @@
 #undef FORMAT2
 }
 
-static char debug_usage[] = 
+static const char debug_usage[] = 
 "Usage: dundi debug\n"
 "       Enables dumping of DUNDi packets for debugging purposes\n";
 
-static char no_debug_usage[] = 
+static const char no_debug_usage[] = 
 "Usage: dundi no debug\n"
 "       Disables dumping of DUNDi packets for debugging purposes\n";
 
-static char store_history_usage[] = 
+static const char store_history_usage[] = 
 "Usage: dundi store history\n"
 "       Enables storing of DUNDi requests and times for debugging\n"
 "purposes\n";
 
-static char no_store_history_usage[] = 
+static const char no_store_history_usage[] = 
 "Usage: dundi no store history\n"
 "       Disables storing of DUNDi requests and times for debugging\n"
 "purposes\n";
 
-static char show_peers_usage[] = 
+static const char show_peers_usage[] = 
 "Usage: dundi show peers\n"
 "       Lists all known DUNDi peers.\n";
 
-static char show_trans_usage[] = 
+static const char show_trans_usage[] = 
 "Usage: dundi show trans\n"
 "       Lists all known DUNDi transactions.\n";
 
-static char show_mappings_usage[] = 
+static const char show_mappings_usage[] = 
 "Usage: dundi show mappings\n"
 "       Lists all known DUNDi mappings.\n";
 
-static char show_precache_usage[] = 
+static const char show_precache_usage[] = 
 "Usage: dundi show precache\n"
 "       Lists all known DUNDi scheduled precache updates.\n";
 
-static char show_entityid_usage[] = 
+static const char show_entityid_usage[] = 
 "Usage: dundi show entityid\n"
 "       Displays the global entityid for this host.\n";
 
-static char show_peer_usage[] = 
+static const char show_peer_usage[] = 
 "Usage: dundi show peer [peer]\n"
 "       Provide a detailed description of a specifid DUNDi peer.\n";
 
-static char show_requests_usage[] = 
+static const char show_requests_usage[] = 
 "Usage: dundi show requests\n"
 "       Lists all known pending DUNDi requests.\n";
 
-static char lookup_usage[] =
+static const char lookup_usage[] =
 "Usage: dundi lookup <number>[@context] [bypass]\n"
 "       Lookup the given number within the given DUNDi context\n"
 "(or e164 if none is specified).  Bypasses cache if 'bypass'\n"
 "keyword is specified.\n";
 
-static char precache_usage[] =
+static const char precache_usage[] =
 "Usage: dundi precache <number>[@context]\n"
 "       Lookup the given number within the given DUNDi context\n"
 "(or e164 if none is specified) and precaches the results to any\n"
 "upstream DUNDi push servers.\n";
 
-static char query_usage[] =
+static const char query_usage[] =
 "Usage: dundi query <entity>[@context]\n"
 "       Attempts to retrieve contact information for a specific\n"
 "DUNDi entity identifier (EID) within a given DUNDi context (or\n"
 "e164 if none is specified).\n";
 
-static char flush_usage[] =
+static const char flush_usage[] =
 "Usage: dundi flush [stats]\n"
 "       Flushes DUNDi answer cache, used primarily for debug.  If\n"
 "'stats' is present, clears timer statistics instead of normal\n"



More information about the svn-commits mailing list