diff options
author | Matt Jordan <mjordan@digium.com> | 2015-11-20 06:15:48 -0600 |
---|---|---|
committer | Gerrit Code Review <gerrit2@gerrit.digium.api> | 2015-11-20 06:15:49 -0600 |
commit | 1ef6c35367e692e6f41ba9e97217bda96406ce4c (patch) | |
tree | 38c50a208949b32c177249aa1bd2924ce34320c2 | |
parent | b52b494004480ec7dfe33b762890ecf220b78f99 (diff) | |
parent | 1bca90fcbe7d3581b9c568361267faf488141868 (diff) |
Merge "res/res_pjsip_outbound_registration: Apply configuration on object type load"
-rw-r--r-- | res/res_pjsip_outbound_registration.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/res/res_pjsip_outbound_registration.c b/res/res_pjsip_outbound_registration.c index 7ff5f1619..7b125334a 100644 --- a/res/res_pjsip_outbound_registration.c +++ b/res/res_pjsip_outbound_registration.c @@ -1846,6 +1846,13 @@ static void registration_loaded_observer(const char *name, const struct ast_sorc return; } + /* + * Refresh the current configured registrations. We don't need to hold + * onto the objects, as the apply handler will cause their states to + * be created appropriately. + */ + ao2_cleanup(get_registrations()); + /* Now to purge dead registrations. */ ao2_callback(states, OBJ_UNLINK | OBJ_NODATA | OBJ_MULTIPLE, check_state, NULL); ao2_ref(states, -1); |