[asterisk-commits] rmudgett: trunk r411073 - in /trunk: main/ utils/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Mar 24 18:36:44 CDT 2014
Author: rmudgett
Date: Mon Mar 24 18:36:36 2014
New Revision: 411073
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=411073
Log:
locking: Add temporary sanity checks.
Add some temporary sanity checks to hunt for locking problems with the
masquerade supertest.
Modified:
trunk/main/lock.c
trunk/utils/ael_main.c
trunk/utils/conf2ael.c
Modified: trunk/main/lock.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/lock.c?view=diff&rev=411073&r1=411072&r2=411073
==============================================================================
--- trunk/main/lock.c (original)
+++ trunk/main/lock.c Mon Mar 24 18:36:36 2014
@@ -311,6 +311,7 @@
}
#endif /* DEBUG_THREADS */
+ ast_assert(res == 0);/*!< \todo BUGBUG Test to ensure that lock/unlock does not fail. */
return res;
}
@@ -417,6 +418,7 @@
__ast_mutex_logger("%s line %d (%s): Error: mutex '%s' is uninitialized and unable to initialize.\n",
filename, lineno, func, mutex_name);
}
+ ast_assert(res == 0);/*!< \todo BUGBUG Test to ensure that lock/unlock does not fail. */
return res;
}
#endif /* AST_MUTEX_INIT_W_CONSTRUCTORS */
@@ -477,6 +479,7 @@
}
#endif /* DEBUG_THREADS */
+ ast_assert(res == 0);/*!< \todo BUGBUG Test to ensure that lock/unlock does not fail. */
return res;
}
Modified: trunk/utils/ael_main.c
URL: http://svnview.digium.com/svn/asterisk/trunk/utils/ael_main.c?view=diff&rev=411073&r1=411072&r2=411073
==============================================================================
--- trunk/utils/ael_main.c (original)
+++ trunk/utils/ael_main.c Mon Mar 24 18:36:36 2014
@@ -36,6 +36,12 @@
void ast_register_file_version(const char *file, const char *version) { }
void ast_unregister_file_version(const char *file) { }
#endif
+
+void __ast_assert_failed(int condition, const char *condition_str, const char *file, int line, const char *function);
+void __ast_assert_failed(int condition, const char *condition_str, const char *file, int line, const char *function)
+{
+ /*! \todo BUGBUG Put here only to allow utils to compile in AST_DEVMODE */
+}
struct ast_flags ast_compat = { 7 };
Modified: trunk/utils/conf2ael.c
URL: http://svnview.digium.com/svn/asterisk/trunk/utils/conf2ael.c?view=diff&rev=411073&r1=411072&r2=411073
==============================================================================
--- trunk/utils/conf2ael.c (original)
+++ trunk/utils/conf2ael.c Mon Mar 24 18:36:36 2014
@@ -79,6 +79,12 @@
//extern char ast_config_AST_CONFIG_DIR[PATH_MAX];
int option_debug = 0;
int option_verbose = 0;
+
+void __ast_assert_failed(int condition, const char *condition_str, const char *file, int line, const char *function);
+void __ast_assert_failed(int condition, const char *condition_str, const char *file, int line, const char *function)
+{
+ /*! \todo BUGBUG Put here only to allow utils to compile in AST_DEVMODE */
+}
void ast_register_file_version(const char *file, const char *version);
void ast_register_file_version(const char *file, const char *version)
More information about the asterisk-commits
mailing list