]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 183436 via svnmerge from
authorDavid Vossel <dvossel@digium.com>
Thu, 19 Mar 2009 20:33:19 +0000 (20:33 +0000)
committerDavid Vossel <dvossel@digium.com>
Thu, 19 Mar 2009 20:33:19 +0000 (20:33 +0000)
https://origsvn.digium.com/svn/asterisk/trunk

................
  r183436 | dvossel | 2009-03-19 15:30:39 -0500 (Thu, 19 Mar 2009) | 13 lines

  Merged revisions 183386 via svnmerge from
  https://origsvn.digium.com/svn/asterisk/branches/1.4

  ........
    r183386 | dvossel | 2009-03-19 14:40:07 -0500 (Thu, 19 Mar 2009) | 6 lines

    Cleaning up a few things in detect disconnect patch

    Initialized ast_call_feature in detect_disconnect to avoid accessing uninitialized memory.  Cleaned up /param tags in features.h.  No longer send dynamic features in ast_feature_detect.

    issue #11583
  ........
................

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

apps/app_dial.c
include/asterisk/features.h
main/features.c

index 5d41f85b485e4b74e06f9af78a331a3b5e06a1d2..984dd8f5c23b6163f256a2f4f94594d53c6fdc3c 100644 (file)
@@ -889,7 +889,7 @@ static struct ast_channel *wait_for_answer(struct ast_channel *in,
 static int detect_disconnect(struct ast_channel *chan, char code, struct ast_str *featurecode)
 {
        struct ast_flags features = { AST_FEATURE_DISCONNECT }; /* only concerned with disconnect feature */
-       struct ast_call_feature feature;
+       struct ast_call_feature feature = { 0, };
        int res;
 
        ast_str_append(&featurecode, 1, "%c", code);
index 7a88abcb159a6af41fe2f2db0b1222269a7f2cf7..9a666c7438f317ecb4a8ba41232326d7b272226f 100644 (file)
@@ -131,7 +131,11 @@ void ast_register_feature(struct ast_call_feature *feature);
 void ast_unregister_feature(struct ast_call_feature *feature);
 
 /*! \brief detect a feature before bridging 
-    \para chan, ast_flags ptr, code, ast_call_feature ptr to be set if found */
+    \param chan
+    \param ast_flags ptr
+    \param char ptr of input code
+    \retval ast_call_feature ptr to be set if found 
+    \return result, was feature found or not */
 int ast_feature_detect(struct ast_channel *chan, struct ast_flags *features, char *code, struct ast_call_feature *feature);
 
 /*! \brief look for a call feature entry by its sname
index dd8aed30b97a54391e6473c6afa303f13fb9f87f..e0461dbb1296933999f2dfa394f492eeaec88168 100644 (file)
@@ -2041,12 +2041,7 @@ static int ast_feature_interpret(struct ast_channel *chan, struct ast_channel *p
 
 int ast_feature_detect(struct ast_channel *chan, struct ast_flags *features, char *code, struct ast_call_feature *feature) {
 
-       char *dynamic_features;
-       ast_channel_lock(chan);
-       dynamic_features = ast_strdupa(S_OR(pbx_builtin_getvar_helper(chan, "DYNAMIC_FEATURES"),""));
-       ast_channel_unlock(chan);
-
-       return feature_interpret_helper(chan, NULL, NULL, code, 0, dynamic_features, features, 0, feature);
+       return feature_interpret_helper(chan, NULL, NULL, code, 0, NULL, features, 0, feature);
 }
 
 static void set_config_flags(struct ast_channel *chan, struct ast_channel *peer, struct ast_bridge_config *config)