]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Remove extra defines of AST_PBX_MAX_STACK.
authorCorey Farrell <git@cfware.com>
Sat, 22 Feb 2014 02:28:07 +0000 (02:28 +0000)
committerCorey Farrell <git@cfware.com>
Sat, 22 Feb 2014 02:28:07 +0000 (02:28 +0000)
* Ensure AST_PBX_MAX_STACK is only defined in extconf.h and pbx.h.
* Fix incorrect function parameters in utils/extconf.c.

(closes issue ASTERISK-23141)
Reported by: Maxim
Review: https://reviewboard.asterisk.org/r/3241/
........

Merged revisions 408785 from http://svn.asterisk.org/svn/asterisk/branches/1.8

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@408786 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/pbx.c
res/ael/pval.c
utils/conf2ael.c
utils/extconf.c

index a3195e0494cada1b09505d661f54394589f7e0d5..72d305b4bb78d232ec8485d82e2bd248c278f690 100644 (file)
@@ -1629,10 +1629,6 @@ int pbx_exec(struct ast_channel *c,      /*!< Channel */
        return res;
 }
 
-
-/*! Go no deeper than this through includes (not counting loops) */
-#define AST_PBX_MAX_STACK      128
-
 /*! \brief Find application handle in linked list
  */
 struct ast_app *pbx_findapp(const char *app)
index 70bd68986263d7217a24dd508efa9185085f6934..dc05cf7f1599c9a76a4617b87baabbbde3c9bedf 100644 (file)
@@ -60,7 +60,6 @@ extern struct ast_flags ast_compat;
 extern int localized_pbx_load_module(void);
 
 static char expr_output[2096];
-#define AST_PBX_MAX_STACK  128
 #define BUF_SIZE 2000
 
 /* these functions are in ../ast_expr2.fl */
index ee46812376f80d1fb1d13ecec7a0c2f2f0fa0541..a59d7b05dddd9627688cadc65ee3319ca0723f8b 100644 (file)
@@ -75,8 +75,6 @@ static int autofallthrough_config = 0;
 static int clearglobalvars_config = 0;
 char ast_config_AST_SYSTEM_NAME[20] = ""; */
 
-/*! Go no deeper than this through includes (not counting loops) */
-#define AST_PBX_MAX_STACK      128
 /* static AST_RWLIST_HEAD_STATIC(acf_root, ast_custom_function); */
 //extern char ast_config_AST_CONFIG_DIR[PATH_MAX];
 int option_debug = 0;
index 7131e13b1738ae6dc52b10e9efc1a10d531efa82..643d70eea1337199fa2cd001fa18bfdb1a7e78af 100644 (file)
@@ -80,6 +80,7 @@ struct ast_channel
 #include "asterisk/inline_api.h"
 #include "asterisk/endian.h"
 #include "asterisk/ast_expr.h"
+#include "asterisk/extconf.h"
 
 /* logger.h */
 
@@ -2677,8 +2678,6 @@ static int static_config = 0;
 static int write_protect_config = 1;
 static int autofallthrough_config = 0;
 static int clearglobalvars_config = 0;
-/*! Go no deeper than this through includes (not counting loops) */
-#define AST_PBX_MAX_STACK      128
 static void pbx_substitute_variables_helper(struct ast_channel *c,const char *cp1,char *cp2,int count);
 
 
@@ -4219,20 +4218,6 @@ struct ast_app;
 #else
 #define EXT_DATA_SIZE 8192
 #endif
-/*!
- * When looking up extensions, we can have different requests
- * identified by the 'action' argument, as follows.
- * Note that the coding is such that the low 4 bits are the
- * third argument to extension_match_core.
- */
-enum ext_match_t {
-       E_MATCHMORE =   0x00,   /* extension can match but only with more 'digits' */
-       E_CANMATCH =    0x01,   /* extension can match with or without more 'digits' */
-       E_MATCH =       0x02,   /* extension is an exact match */
-       E_MATCH_MASK =  0x03,   /* mask for the argument to extension_match_core() */
-       E_SPAWN =       0x12,   /* want to spawn an extension. Requires exact match */
-       E_FINDLABEL =   0x22    /* returns the priority for a given label. Requires exact match */
-};
 
 #ifdef NOT_ANYMORE
 static AST_RWLIST_HEAD_STATIC(switches, ast_switch);
@@ -4759,22 +4744,6 @@ static struct ast_context *ast_context_find(const char *name)
        return tmp;
 }
 
-/* request and result for pbx_find_extension */
-struct pbx_find_info {
-#if 0
-       const char *context;
-       const char *exten;
-       int priority;
-#endif
-
-       char *incstack[AST_PBX_MAX_STACK];      /* filled during the search */
-       int stacklen;                   /* modified during the search */
-       int status;                     /* set on return */
-       struct ast_switch *swo;         /* set on return */
-       const char *data;               /* set on return */
-       const char *foundcontext;       /* set on return */
-};
-
 /*
  * Internal function for ast_extension_{match|close}
  * return 0 on no-match, 1 on match, 2 on early match.
@@ -6205,9 +6174,7 @@ static void ast_merge_contexts_and_delete(struct ast_context **extcontexts, cons
        return;
 }
 
-void localized_merge_contexts_and_delete(struct ast_context **extcontexts, const char *registrar);
-
-void localized_merge_contexts_and_delete(struct ast_context **extcontexts, const char *registrar)
+void localized_merge_contexts_and_delete(struct ast_context **extcontexts, void *tab, const char *registrar)
 {
        ast_merge_contexts_and_delete(extcontexts, registrar);
 }