[svn-commits] dlee: branch dlee/performance r399499 - /team/dlee/performance/main/astobj2.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Thu Sep 19 16:35:34 CDT 2013


Author: dlee
Date: Thu Sep 19 16:35:32 2013
New Revision: 399499

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=399499
Log:
But always clear the magic number.

Modified:
    team/dlee/performance/main/astobj2.c

Modified: team/dlee/performance/main/astobj2.c
URL: http://svnview.digium.com/svn/asterisk/team/dlee/performance/main/astobj2.c?view=diff&rev=399499&r1=399498&r2=399499
==============================================================================
--- team/dlee/performance/main/astobj2.c (original)
+++ team/dlee/performance/main/astobj2.c Thu Sep 19 16:35:32 2013
@@ -523,6 +523,9 @@
 			"Invalid lock option on ao2 object %p\n", user_data);
 		break;
 	}
+
+	/* In case someone uses an object after it's been freed */
+	obj->priv_data.magic = 0;
 
 	return ret;
 }




More information about the svn-commits mailing list