Audit of ao2_iterator_init() usage for v1.8.

Fixes numerous reference leaks and missing ao2_iterator_destroy() calls as
a result.

Review: https://reviewboard.asterisk.org/r/1697/


git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.8@352955 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Richard Mudgett
2012-01-27 18:22:39 +00:00
parent 4d2f8a9cfd
commit a55030f4fa
11 changed files with 89 additions and 55 deletions

View File

@@ -658,6 +658,7 @@ static char *complete_country(struct ast_cli_args *a)
break;
}
}
ao2_iterator_destroy(&i);
return res;
}
@@ -835,6 +836,7 @@ static char *handle_cli_indication_show(struct ast_cli_entry *e, int cmd, struct
ast_tone_zone_unlock(tz);
tz = ast_tone_zone_unref(tz);
}
ao2_iterator_destroy(&iter);
return CLI_SUCCESS;
}