aboutsummaryrefslogtreecommitdiffstats
path: root/formats/format_gsm.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-09 15:28:59 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-09 15:28:59 +0000
commit410225d9651a936e85dba001ee693664fdc5c8f4 (patch)
tree06bd373dccdd5d5e67fbd69767558f87dc4238f4 /formats/format_gsm.c
parent604872d772869fbe7d78a4e21940cdca32da9429 (diff)
Set a module load priority for format modules.
A recent change to app_voicemail made it such that the module now assumes that all format modules are available while processing voicemail configuration. However, when autoloading modules, it was possible that app_voicemail was loaded before the format modules. Since format modules don't depend on anything, set a module load priority on them to ensure that they get loaded first when autoloading. This version of the patch is specific to Asterisk 1.4 and 1.6.0. These versions did not already support module load priority in the module API. This adds a trivial version of this which is just a module flag to include it in a pass before loading "everything". Thanks to mmichelson for the review! (closes issue #16412) Reported by: jiddings Tested by: russell Review: https://reviewboard.asterisk.org/r/445/ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@233841 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'formats/format_gsm.c')
-rw-r--r--formats/format_gsm.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/formats/format_gsm.c b/formats/format_gsm.c
index d8a0813b6..073d5d606 100644
--- a/formats/format_gsm.c
+++ b/formats/format_gsm.c
@@ -169,4 +169,7 @@ static int unload_module(void)
return ast_format_unregister(gsm_f.name);
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "Raw GSM data");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_FIRST, "Raw GSM data",
+ .load = load_module,
+ .unload = unload_module,
+);