GetStatementAtAddress(): Terminate, if we couldn't get the statement from the

disassembled code of the function.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@31685 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ingo Weinhold
2009-07-22 01:53:59 +00:00
parent ae8f22407a
commit 25598171b1
+7 -6
View File
@@ -242,12 +242,13 @@ printf(" -> no function instance\n");
// statement directly.
if (DisassembledCode* code = functionInstance->GetSourceCode()) {
Statement* statement = code->StatementAtAddress(address);
if (statement != NULL) {
statement->AcquireReference();
_statement = statement;
_function = functionInstance;
return B_OK;
}
if (statement == NULL)
return B_ENTRY_NOT_FOUND;
statement->AcquireReference();
_statement = statement;
_function = functionInstance;
return B_OK;
}
// get the statement from the image debug info