[asterisk-commits] dvossel: branch 1.6.2 r202411 - in /branches/1.6.2: ./ include/asterisk/ main/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Jun 22 10:37:59 CDT 2009


Author: dvossel
Date: Mon Jun 22 10:37:55 2009
New Revision: 202411

URL: http://svn.asterisk.org/svn-view/asterisk?view=rev&rev=202411
Log:
Merged revisions 202410 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

........
  r202410 | dvossel | 2009-06-22 10:33:35 -0500 (Mon, 22 Jun 2009) | 5 lines
  
  attempting to load running modules
  
  Modules placed in the priority heap for loading were not properly removed from the linked list.  This resulted in some modules attempting to load twice.
........

Modified:
    branches/1.6.2/   (props changed)
    branches/1.6.2/include/asterisk/module.h
    branches/1.6.2/main/loader.c

Propchange: branches/1.6.2/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.

Modified: branches/1.6.2/include/asterisk/module.h
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.2/include/asterisk/module.h?view=diff&rev=202411&r1=202410&r2=202411
==============================================================================
--- branches/1.6.2/include/asterisk/module.h (original)
+++ branches/1.6.2/include/asterisk/module.h Mon Jun 22 10:37:55 2009
@@ -58,10 +58,11 @@
 };
 
 enum ast_module_load_result {
-	AST_MODULE_LOAD_SUCCESS = 0,	/*!< Module loaded and configured */
-	AST_MODULE_LOAD_DECLINE = 1,	/*!< Module is not configured */
-	AST_MODULE_LOAD_SKIP = 2,	/*!< Module was skipped for some reason */
-	AST_MODULE_LOAD_FAILURE = -1,	/*!< Module could not be loaded properly */
+	AST_MODULE_LOAD_SUCCESS = 0,    /*!< Module loaded and configured */
+	AST_MODULE_LOAD_DECLINE = 1,    /*!< Module is not configured */
+	AST_MODULE_LOAD_SKIP = 2,       /*!< Module was skipped for some reason */
+	AST_MODULE_LOAD_PRIORITY = 3,   /*!< Module is not loaded yet, but is added to prioity heap */
+	AST_MODULE_LOAD_FAILURE = -1,   /*!< Module could not be loaded properly */
 };
 
 /*! 

Modified: branches/1.6.2/main/loader.c
URL: http://svn.asterisk.org/svn-view/asterisk/branches/1.6.2/main/loader.c?view=diff&rev=202411&r1=202410&r2=202411
==============================================================================
--- branches/1.6.2/main/loader.c (original)
+++ branches/1.6.2/main/loader.c Mon Jun 22 10:37:55 2009
@@ -744,9 +744,8 @@
 		mod->flags.declined = 1;
 		break;
 	case AST_MODULE_LOAD_FAILURE:
-		break;
-	case AST_MODULE_LOAD_SKIP:
-		/* modules should never return this value */
+	case AST_MODULE_LOAD_SKIP: /* modules should never return this value */
+	case AST_MODULE_LOAD_PRIORITY:
 		break;
 	}
 
@@ -808,7 +807,7 @@
 
 	if (resource_heap) {
 		ast_heap_push(resource_heap, mod);
-		res = AST_MODULE_LOAD_SKIP;
+		res = AST_MODULE_LOAD_PRIORITY;
 	} else {
 		res = start_resource(mod);
 	}
@@ -894,6 +893,9 @@
 			goto done;
 		case AST_MODULE_LOAD_SKIP:
 			break;
+		case AST_MODULE_LOAD_PRIORITY:
+			AST_LIST_REMOVE_CURRENT(entry);
+			break;
 		}
 	}
 	AST_LIST_TRAVERSE_SAFE_END;
@@ -909,6 +911,7 @@
 			res = -1;
 			goto done;
 		case AST_MODULE_LOAD_SKIP:
+		case AST_MODULE_LOAD_PRIORITY:
 			break;
 		}
 	}




More information about the asterisk-commits mailing list