mirror of
https://github.com/rizinorg/cutter.git
synced 2024-12-19 03:16:10 +00:00
fix segfault when pressing f or t in graph mode without a defined func
This commit is contained in:
parent
9501ecf38c
commit
f7d1ce8771
@ -653,6 +653,10 @@ void DisassemblerGraphView::zoomReset()
|
|||||||
void DisassemblerGraphView::takeTrue()
|
void DisassemblerGraphView::takeTrue()
|
||||||
{
|
{
|
||||||
DisassemblyBlock *db = blockForAddress(seekable->getOffset());
|
DisassemblyBlock *db = blockForAddress(seekable->getOffset());
|
||||||
|
if (!db) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (db->true_path != RVA_INVALID) {
|
if (db->true_path != RVA_INVALID) {
|
||||||
seekable->seek(db->true_path);
|
seekable->seek(db->true_path);
|
||||||
} else if (blocks[db->entry].exits.size()) {
|
} else if (blocks[db->entry].exits.size()) {
|
||||||
@ -663,6 +667,10 @@ void DisassemblerGraphView::takeTrue()
|
|||||||
void DisassemblerGraphView::takeFalse()
|
void DisassemblerGraphView::takeFalse()
|
||||||
{
|
{
|
||||||
DisassemblyBlock *db = blockForAddress(seekable->getOffset());
|
DisassemblyBlock *db = blockForAddress(seekable->getOffset());
|
||||||
|
if (!db) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (db->false_path != RVA_INVALID) {
|
if (db->false_path != RVA_INVALID) {
|
||||||
seekable->seek(db->false_path);
|
seekable->seek(db->false_path);
|
||||||
} else if (blocks[db->entry].exits.size()) {
|
} else if (blocks[db->entry].exits.size()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user