summaryrefslogtreecommitdiff
path: root/pbx
diff options
context:
space:
mode:
authorRussell Bryant <russell@russellbryant.com>2005-05-19 01:57:19 +0000
committerRussell Bryant <russell@russellbryant.com>2005-05-19 01:57:19 +0000
commit3c98814bb50132c41b093f82813cf5003e0995c8 (patch)
treeb006587477d09e5bc5e13f401a06e2e7c0e82dad /pbx
parent53d655cf0af46985576959ddc42f95f014e44dc8 (diff)
add 'dontwarn' option to asterisk.conf to appease the whining masses :p (bug #4320)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@5723 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'pbx')
-rwxr-xr-xpbx/pbx_config.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/pbx/pbx_config.c b/pbx/pbx_config.c
index fc069e12b..8aa523c5a 100755
--- a/pbx/pbx_config.c
+++ b/pbx/pbx_config.c
@@ -14,6 +14,7 @@
#include <sys/types.h>
#include "asterisk/pbx.h"
#include "asterisk/config.h"
+#include "asterisk/options.h"
#include "asterisk/module.h"
#include "asterisk/logger.h"
#include "asterisk/cli.h"
@@ -1742,8 +1743,10 @@ static int pbx_load_module(void)
if (plus)
ipri += atoi(plus);
lastpri = ipri;
- if (!strcmp(realext, "_."))
- ast_log(LOG_WARNING, "The use of '_.' for an extension is strongly discouraged and can have unexpected behavior. Please use '_X.' instead at line %d\n", v->lineno);
+ if(!option_dontwarn) {
+ if (!strcmp(realext, "_."))
+ ast_log(LOG_WARNING, "The use of '_.' for an extension is strongly discouraged and can have unexpected behavior. Please use '_X.' instead at line %d\n", v->lineno);
+ }
if (ast_add_extension2(con, 0, realext, ipri, label, cidmatch, appl, strdup(data), FREE, registrar)) {
ast_log(LOG_WARNING, "Unable to register extension at line %d\n", v->lineno);
}