]> 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:50:24 +0000 (16:50 +0000)
committerKinsey Moore <kmoore@digium.com>
Tue, 4 Mar 2014 16:50:24 +0000 (16:50 +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.

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

main/astobj2.c

index 189cfc9bbcdc39135ec9b66f4442bd1213269316..2d866d6a2559cc27a93662cecfdcae76f24815ae 100644 (file)
@@ -126,6 +126,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;
        }