]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
AO2: Add an assert for bad objects
authorKinsey Moore <kmoore@digium.com>
Tue, 4 Mar 2014 16:51:11 +0000 (16:51 +0000)
committerKinsey Moore <kmoore@digium.com>
Tue, 4 Mar 2014 16:51:11 +0000 (16:51 +0000)
This adds an assert that will only be active if Asterisk is compiled
with DO_CRASH and allows the testsuite to fail tests that would
otherwise require log file parsing.
........

Merged revisions 409566 from http://svn.asterisk.org/svn/asterisk/branches/1.8

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@409567 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/astobj2.c

index 35dd17172e08b90abd64797388b2b223c82a23ad..c4098bfc9c57304c4f9494104a8e1b639b7596d3 100644 (file)
@@ -157,6 +157,7 @@ static inline struct astobj2 *INTERNAL_OBJ(void *user_data)
                                "bad magic number for object %p. Object is likely destroyed.\n",
                                user_data);
                }
+               ast_assert(0);
                return NULL;
        }