Avoid a crash if we don't pass an argument to 'astobj2 test.'

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@297775 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.4
Sean Bright 15 years ago
parent 4369b3c4ae
commit 0135ff19ed

@ -758,6 +758,10 @@ static int handle_astobj2_test(int fd, int argc, char *argv[])
char *obj;
static int prof_id = -1;
if (argc != 3) {
return RESULT_SHOWUSAGE;
}
if (prof_id == -1)
prof_id = ast_add_profile("ao2_alloc", 0);

Loading…
Cancel
Save