Fix some opaquification-related compiler warnings

(closes issue ASTERISK-19419)
PseudoReview - seanbright on IRC


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@356152 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Terry Wilson
2012-02-21 20:17:52 +00:00
parent 1c971ae604
commit c25a442dfb
3 changed files with 16 additions and 10 deletions

View File

@@ -104,12 +104,14 @@ int ast_framehook_attach(struct ast_channel *chan, struct ast_framehook_interfac
framehook->chan = chan;
/* create the framehook list if it didn't already exist */
if (!ast_channel_framehooks(chan) && !(fh_list = ast_calloc(1, sizeof(*ast_channel_framehooks(chan))))) {
ast_free(framehook);
return -1;
if (!ast_channel_framehooks(chan)) {
if (!(fh_list = ast_calloc(1, sizeof(*ast_channel_framehooks(chan))))) {
ast_free(framehook);
return -1;
}
ast_channel_framehooks_set(chan, fh_list);
}
ast_channel_framehooks_set(chan, fh_list);
framehook->id = ++ast_channel_framehooks(chan)->id_count;
AST_LIST_INSERT_TAIL(&ast_channel_framehooks(chan)->list, framehook, list);