From: Jason Parker Date: Tue, 3 Mar 2009 23:01:06 +0000 (+0000) Subject: Make sure we still support zapchan in users.conf, in addition to dahdichan. X-Git-Tag: 1.4.24-rc1~10 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5a3bc6b38da7fd3524b70aca59ebba621a68a807;p=thirdparty%2Fasterisk.git Make sure we still support zapchan in users.conf, in addition to dahdichan. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@180010 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c index 8ba2d81997..291dc47620 100644 --- a/channels/chan_dahdi.c +++ b/channels/chan_dahdi.c @@ -12087,13 +12087,11 @@ static int setup_dahdi(int reload) cfg = ast_config_load("users.conf"); if (cfg) { char *cat; - const char *chans; process_dahdi(&conf, "", ast_variable_browse(cfg, "general"), 1, 1); for (cat = ast_category_browse(cfg, NULL); cat ; cat = ast_category_browse(cfg, cat)) { if (!strcasecmp(cat, "general")) continue; - chans = ast_variable_retrieve(cfg, cat, "dahdichan"); - if (!ast_strlen_zero(chans)) { + if (!ast_strlen_zero(ast_variable_retrieve(cfg, cat, "dahdichan")) || !ast_strlen_zero(ast_variable_retrieve(cfg, cat, "zapchan"))) { struct dahdi_chan_conf sect_conf; memcpy(§_conf, &conf, sizeof(sect_conf));