[svn-commits] russell: branch russell/iax_refcount r80290 - /team/russell/iax_refcount/main/
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Wed Aug 22 12:10:06 CDT 2007
Author: russell
Date: Wed Aug 22 12:10:05 2007
New Revision: 80290
URL: http://svn.digium.com/view/asterisk?view=rev&rev=80290
Log:
remove usage of assert, as we do not use it anywhere else
Modified:
team/russell/iax_refcount/main/astobj2.c
Modified: team/russell/iax_refcount/main/astobj2.c
URL: http://svn.digium.com/view/asterisk/team/russell/iax_refcount/main/astobj2.c?view=diff&rev=80290&r1=80289&r2=80290
==============================================================================
--- team/russell/iax_refcount/main/astobj2.c (original)
+++ team/russell/iax_refcount/main/astobj2.c Wed Aug 22 12:10:05 2007
@@ -18,7 +18,6 @@
* Function implementing astobj2 objects.
*/
#include "asterisk.h"
-#include <assert.h>
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
@@ -95,10 +94,11 @@
{
struct astobj2 *p;
- if (user_data == NULL) {
- ao2_bt();
- assert(user_data != NULL);
- }
+ if (!user_data) {
+ ast_log(LOG_ERROR, "user_data is NULL\n");
+ return NULL;
+ }
+
p = (struct astobj2 *)((char *)(user_data) - sizeof(struct astobj2));
if (AO2_MAGIC != (p->priv_data.magic) ) {
ast_verbose("----!!!!!--------- bad magic number 0x%x for %p\n", p->priv_data.magic, p);
More information about the svn-commits
mailing list