aboutsummaryrefslogtreecommitdiffstats
path: root/formats/format_jpeg.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-09 15:14:21 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2009-12-09 15:14:21 +0000
commit0e5b47cc9c04b3ee976c6c6fce7b85659c0fad44 (patch)
tree8ce320876e92387b42556b037f1896f243cc0204 /formats/format_jpeg.c
parentc806a7780cd92b3f3ee6f28a9956d9a4d591588d (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.4@233782 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'formats/format_jpeg.c')
-rw-r--r--formats/format_jpeg.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/formats/format_jpeg.c b/formats/format_jpeg.c
index edef171d2..64c197a99 100644
--- a/formats/format_jpeg.c
+++ b/formats/format_jpeg.c
@@ -124,4 +124,7 @@ static int unload_module(void)
return 0;
}
-AST_MODULE_INFO_STANDARD(ASTERISK_GPL_KEY, "JPEG (Joint Picture Experts Group) Image Format");
+AST_MODULE_INFO(ASTERISK_GPL_KEY, AST_MODFLAG_LOAD_FIRST, "JPEG (Joint Picture Experts Group) Image Format",
+ .load = load_module,
+ .unload = unload_module,
+);