mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-03 11:25:35 +00:00
Eliminate some more unnecessary RAII_VAR() uses.
RAII_VAR() is not a hammer appropriate to pound all nails. ........ Merged revisions 412413 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@412414 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -890,11 +890,10 @@ static void generate_or_link_lots_to_configs(void)
|
||||
struct parking_lot_cfg *lot_cfg;
|
||||
struct ao2_iterator iter;
|
||||
|
||||
for (iter = ao2_iterator_init(cfg->parking_lots, 0); (lot_cfg = ao2_iterator_next(&iter)); ao2_ref(lot_cfg, -1)) {
|
||||
RAII_VAR(struct parking_lot *, lot, NULL, ao2_cleanup);
|
||||
lot = parking_lot_build_or_update(lot_cfg, 0);
|
||||
iter = ao2_iterator_init(cfg->parking_lots, 0);
|
||||
for (; (lot_cfg = ao2_iterator_next(&iter)); ao2_ref(lot_cfg, -1)) {
|
||||
ao2_cleanup(parking_lot_build_or_update(lot_cfg, 0));
|
||||
}
|
||||
|
||||
ao2_iterator_destroy(&iter);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user