From b8243a2b615aaaf14cc7745fff69694337cc784d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=A4rkl?= Date: Mon, 14 Mar 2022 10:09:35 +0100 Subject: [PATCH] Remove unused stats query (#2903) The views showing this info have been removed in the past, so it was unused. This also fixes some errors with latest rizin where zero-argument f does not exist anymore (it's now fl). --- src/core/Cutter.cpp | 26 -------------------------- src/core/Cutter.h | 1 - src/widgets/Dashboard.cpp | 3 --- 3 files changed, 30 deletions(-) diff --git a/src/core/Cutter.cpp b/src/core/Cutter.cpp index bb0b661a..d5db389b 100644 --- a/src/core/Cutter.cpp +++ b/src/core/Cutter.cpp @@ -2653,32 +2653,6 @@ QList CutterCore::getMemoryMap() return ret; } -QStringList CutterCore::getStats() -{ - QStringList stats; - cmdRaw("fs functions"); - - // The cmd coomand is frequently used in this function because - // cmdRaw would not work with grep - stats << cmd("f~?").trimmed(); - - QString imps = cmd("ii~?").trimmed(); - stats << imps; - - cmdRaw("fs symbols"); - stats << cmd("f~?").trimmed(); - cmdRaw("fs strings"); - stats << cmd("f~?").trimmed(); - cmdRaw("fs relocs"); - stats << cmd("f~?").trimmed(); - cmdRaw("fs sections"); - stats << cmd("f~?").trimmed(); - cmdRaw("fs *"); - stats << cmd("f~?").trimmed(); - - return stats; -} - void CutterCore::setGraphEmpty(bool empty) { emptyGraph = empty; diff --git a/src/core/Cutter.h b/src/core/Cutter.h index c1e21e50..249da7ce 100644 --- a/src/core/Cutter.h +++ b/src/core/Cutter.h @@ -559,7 +559,6 @@ public: CutterJson getFileInfo(); CutterJson getSignatureInfo(); CutterJson getFileVersionInfo(); - QStringList getStats(); void setGraphEmpty(bool empty); bool isGraphEmpty(); diff --git a/src/widgets/Dashboard.cpp b/src/widgets/Dashboard.cpp index 4f49739a..c0d0cf87 100644 --- a/src/widgets/Dashboard.cpp +++ b/src/widgets/Dashboard.cpp @@ -151,9 +151,6 @@ void Dashboard::updateContents() QSpacerItem *spacer = new QSpacerItem(1, 1, QSizePolicy::Fixed, QSizePolicy::Expanding); ui->verticalLayout_2->addSpacerItem(spacer); - // Get stats for the graphs - QStringList stats = Core()->getStats(); - // Check if signature info and version info available if (!Core()->getSignatureInfo().size()) { ui->certificateButton->setEnabled(false);