[asterisk-commits] kpfleming: branch 1.4 r44322 - in /branches/1.4: ./ include/ main/

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Tue Oct 3 17:25:45 MST 2006


Author: kpfleming
Date: Tue Oct  3 19:25:44 2006
New Revision: 44322

URL: http://svn.digium.com/view/asterisk?rev=44322&view=rev
Log:
ensure that local include files are always used
avoid a duplicate function name (term_init())

Modified:
    branches/1.4/Makefile
    branches/1.4/include/asterisk.h
    branches/1.4/main/asterisk.c
    branches/1.4/main/loader.c
    branches/1.4/main/term.c

Modified: branches/1.4/Makefile
URL: http://svn.digium.com/view/asterisk/branches/1.4/Makefile?rev=44322&r1=44321&r2=44322&view=diff
==============================================================================
--- branches/1.4/Makefile (original)
+++ branches/1.4/Makefile Tue Oct  3 19:25:44 2006
@@ -136,8 +136,8 @@
 GLOBAL_MAKEOPTS=$(wildcard /etc/asterisk.makeopts)
 USER_MAKEOPTS=$(wildcard ~/.asterisk.makeopts)
 
-MOD_SUBDIR_CFLAGS=-I../include
-OTHER_SUBDIR_CFLAGS=-I../include
+MOD_SUBDIR_CFLAGS=-I$(ASTTOPDIR)/include
+OTHER_SUBDIR_CFLAGS=-I$(ASTTOPDIR)/include
 
 ifeq ($(OSARCH),linux-gnu)
   ifeq ($(PROC),x86_64)

Modified: branches/1.4/include/asterisk.h
URL: http://svn.digium.com/view/asterisk/branches/1.4/include/asterisk.h?rev=44322&r1=44321&r2=44322&view=diff
==============================================================================
--- branches/1.4/include/asterisk.h (original)
+++ branches/1.4/include/asterisk.h Tue Oct  3 19:25:44 2006
@@ -57,7 +57,7 @@
 void close_logger(void);			/*!< Provided by logger.c */
 int reload_logger(int);				/*!< Provided by logger.c */
 int init_framer(void);				/*!< Provided by frame.c */
-int term_init(void);				/*!< Provided by term.c */
+int ast_term_init(void);			/*!< Provided by term.c */
 int astdb_init(void);				/*!< Provided by db.c */
 void ast_channels_init(void);			/*!< Provided by channel.c */
 void ast_builtins_init(void);			/*!< Provided by cli.c */

Modified: branches/1.4/main/asterisk.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/asterisk.c?rev=44322&r1=44321&r2=44322&view=diff
==============================================================================
--- branches/1.4/main/asterisk.c (original)
+++ branches/1.4/main/asterisk.c Tue Oct  3 19:25:44 2006
@@ -2619,7 +2619,7 @@
 	}
 #endif
 
-	term_init();
+	ast_term_init();
 	printf(term_end());
 	fflush(stdout);
 

Modified: branches/1.4/main/loader.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/loader.c?rev=44322&r1=44321&r2=44322&view=diff
==============================================================================
--- branches/1.4/main/loader.c (original)
+++ branches/1.4/main/loader.c Tue Oct  3 19:25:44 2006
@@ -359,7 +359,7 @@
 	strcpy(resource_being_loaded->resource, resource);
 
 	if (!(lib = dlopen(fn, RTLD_LAZY | RTLD_LOCAL))) {
-		ast_log(LOG_WARNING, "%s\n", dlerror());
+		ast_log(LOG_WARNING, "Error loading module '%s': %s\n", resource_in, dlerror());
 		free(resource_being_loaded);
 		return NULL;
 	}
@@ -372,6 +372,7 @@
 	   module_list
 	*/
 	if (resource_being_loaded != (mod = AST_LIST_LAST(&module_list))) {
+		ast_log(LOG_WARNING, "Module '%s' did not register itself during load\n", resource_in);
 		/* no, it did not, so close it and return */
 		while (!dlclose(lib));
 		/* note that the module's destructor will call ast_module_unregister(),
@@ -394,7 +395,7 @@
 	*/
 #if HAVE_RTLD_NOLOAD
 	if (!dlopen(fn, RTLD_NOLOAD | (wants_global ? RTLD_LAZY | RTLD_GLOBAL : RTLD_NOW | RTLD_LOCAL))) {
-		ast_log(LOG_WARNING, "%s\n", dlerror());
+		ast_log(LOG_WARNING, "Unable to promot flags on module '%s': %s\n", resource_in, dlerror());
 		while (!dlclose(lib));
 		free(resource_being_loaded);
 		return NULL;
@@ -411,7 +412,7 @@
 	strcpy(resource_being_loaded->resource, resource);
 
 	if (!(lib = dlopen(fn, wants_global ? RTLD_LAZY | RTLD_GLOBAL : RTLD_NOW | RTLD_LOCAL))) {
-		ast_log(LOG_WARNING, "%s\n", dlerror());
+		ast_log(LOG_WARNING, "Error loading module '%s': %s\n", resource_in, dlerror());
 		free(resource_being_loaded);
 		return NULL;
 	}

Modified: branches/1.4/main/term.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/term.c?rev=44322&r1=44321&r2=44322&view=diff
==============================================================================
--- branches/1.4/main/term.c (original)
+++ branches/1.4/main/term.c Tue Oct  3 19:25:44 2006
@@ -72,7 +72,7 @@
 	return a + b * 256;
 }
 
-int term_init(void)
+int ast_term_init(void)
 {
 	char *term = getenv("TERM");
 	char termfile[256] = "";



More information about the asterisk-commits mailing list