[svn-commits] mmichelson: trunk r391269 - /trunk/main/features_config.c
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Mon Jun 10 10:32:04 CDT 2013
Author: mmichelson
Date: Mon Jun 10 10:32:02 2013
New Revision: 391269
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=391269
Log:
Temporary fix for people using sample features.conf from previous Asterisk versions.
People who use the features.conf.sample file from Asterisk 11 and before in trunk were
given a rude awakening when features configuration changes were made. Because it uses the
config framework and the config framework is strict about what is accepted and what isn't,
people that had parking options configured found that Asterisk no longer started. This is
because parking options are currently handled in res_parking.conf instead of features.conf.
This fix seeks to create a temporary band-aid fix for the problem, but having parking options
from the general section be passed to a handler that will simply print that the option is no
longer supported. This will not cause Asterisk to exit.
The fix only applies to options in the general section. There are two main reasons for this:
1) The sample features.conf file only has parking options in the general section. There are no
configured parking lots. Therefore it's not quite as "urgent" to get the parking lot parsing
fixed.
2) The plan is to move parking configuration back from res_parking.conf to features.conf. When
that happens, the parking lots will also be addressed at that time.
Modified:
trunk/main/features_config.c
Modified: trunk/main/features_config.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/features_config.c?view=diff&rev=391269&r1=391268&r2=391269
==============================================================================
--- trunk/main/features_config.c (original)
+++ trunk/main/features_config.c Mon Jun 10 10:32:02 2013
@@ -1168,6 +1168,13 @@
return pickup_set(pickup, var->name, var->value);
}
+static int unsupported_handler(const struct aco_option *opt,
+ struct ast_variable *var, void *obj)
+{
+ ast_log(LOG_WARNING, "The option '%s' is no longer configurable in features.conf.\n", var->name);
+ return 0;
+}
+
static int featuremap_handler(const struct aco_option *opt,
struct ast_variable *var, void *obj)
{
@@ -1378,6 +1385,41 @@
aco_option_register_custom(&cfg_info, "pickupfailsound", ACO_EXACT, global_options,
DEFAULT_PICKUPFAILSOUND, pickup_handler, 0);
+ aco_option_register_custom(&cfg_info, "context", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkext", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkext_exclusive", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkinghints", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkedmusicclass", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkingtime", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkpos", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "findslot", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkedcalltransfers", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkedcallreparking", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkedcallhangup", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkedcallrecording", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "comebackcontext", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "comebacktoorigin", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "comebackdialtime", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "parkeddynamic", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+ aco_option_register_custom(&cfg_info, "adsipark", ACO_EXACT, global_options,
+ "", unsupported_handler, 0);
+
aco_option_register_custom(&cfg_info, "blindxfer", ACO_EXACT, featuremap_options,
DEFAULT_FEATUREMAP_BLINDXFER, featuremap_handler, 0);
aco_option_register_custom(&cfg_info, "disconnect", ACO_EXACT, featuremap_options,
More information about the svn-commits
mailing list