aboutsummaryrefslogtreecommitdiffstats
path: root/apps/app_externalivr.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-05-11 20:07:44 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-05-11 20:07:44 +0000
commitda3cf563ba87b9cd244f931cfe5c23d17dabafd5 (patch)
treef91bfa1dc51a7b5350dd534e72ed17e37cdd2b25 /apps/app_externalivr.c
parentd681ea85987a742eaa276d37b06ba2052c0a5cd0 (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: http://svn.digium.com/svn/asterisk/trunk@26990 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_externalivr.c')
-rw-r--r--apps/app_externalivr.c10
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;