From 0e5b47cc9c04b3ee976c6c6fce7b85659c0fad44 Mon Sep 17 00:00:00 2001 From: russell Date: Wed, 9 Dec 2009 15:14:21 +0000 Subject: 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 --- formats/format_jpeg.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'formats/format_jpeg.c') 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, +); -- cgit v1.2.3