diff options
author | Mark Michelson <mmichelson@digium.com> | 2014-04-02 18:57:29 +0000 |
---|---|---|
committer | Mark Michelson <mmichelson@digium.com> | 2014-04-02 18:57:29 +0000 |
commit | eefcb79bfb4ce2bd0236fc4bb5d960a6df9f3cc4 (patch) | |
tree | 15e35325d8e0cd53f0dae6bfbb987abb84456bc2 /tests/test_sorcery_astdb.c | |
parent | c704795dcbc5caa5676a1685d6a5996e92875ae9 (diff) |
Prevent duplicate sorcery wizards from being applied to sorcery object types.
This commit contains several changes to sorcery:
1) Application of sorcery configuration based on module name is automatically performed
when sorcery is opened for a module.
2) Sorcery will not attempt to apply the same wizard to an object type more than once.
3) Sorcery gives more exact results when attempting to apply a wizard, whether as the
default or based on configuration.
Sorcery unit tests still pass for me after making these changes.
Review: https://reviewboard.asterisk.org/r/3326
........
Merged revisions 411159 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411656 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'tests/test_sorcery_astdb.c')
-rw-r--r-- | tests/test_sorcery_astdb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/test_sorcery_astdb.c b/tests/test_sorcery_astdb.c index 41e7adbc9..b87ed74f8 100644 --- a/tests/test_sorcery_astdb.c +++ b/tests/test_sorcery_astdb.c @@ -60,7 +60,7 @@ static struct ast_sorcery *alloc_and_initialize_sorcery(void) return NULL; } - if (ast_sorcery_apply_default(sorcery, "test", "astdb", "test") || + if ((ast_sorcery_apply_default(sorcery, "test", "astdb", "test") != AST_SORCERY_APPLY_SUCCESS) || ast_sorcery_internal_object_register(sorcery, "test", test_sorcery_object_alloc, NULL, NULL)) { ast_sorcery_unref(sorcery); return NULL; |