diff options
author | Russell Bryant <russell@russellbryant.com> | 2006-05-11 20:07:44 +0000 |
---|---|---|
committer | Russell Bryant <russell@russellbryant.com> | 2006-05-11 20:07:44 +0000 |
commit | f9c578a8a05beb342a4e02648c35b4b2939d11ba (patch) | |
tree | f91bfa1dc51a7b5350dd534e72ed17e37cdd2b25 /apps/app_externalivr.c | |
parent | 126ce7882c857925f24573b4e82fddc888e1ace3 (diff) |
- The recent change to linklists.h broke the build on linux for some reason.
So, I have removed all of the uses of AST_LIST_HEAD_INIT and replaced them
with the equivalent static initializations.
- On passing, fix a memory leak in the unload_module() function of chan_agent.
The agents list mutex was never destroyed, and the elements in the agents
list were not freed.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@26990 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'apps/app_externalivr.c')
-rw-r--r-- | apps/app_externalivr.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/apps/app_externalivr.c b/apps/app_externalivr.c index ecc8bf888..e29a3655e 100644 --- a/apps/app_externalivr.c +++ b/apps/app_externalivr.c @@ -258,14 +258,14 @@ static int app_exec(struct ast_channel *chan, void *data) FILE *child_commands = NULL; FILE *child_errors = NULL; FILE *child_events = NULL; - struct ivr_localuser foo, *u = &foo; - - bzero(u, sizeof(*u)); + struct ivr_localuser foo = { + .playlist = AST_LIST_HEAD_INIT_VALUE, + .finishlist = AST_LIST_HEAD_INIT_VALUE, + }; + struct ivr_localuser *u = &foo; LOCAL_USER_ADD(lu); - AST_LIST_HEAD_INIT(&u->playlist); - AST_LIST_HEAD_INIT(&u->finishlist); u->abort_current_sound = 0; u->chan = chan; |