mirror of
https://github.com/rizinorg/cutter.git
synced 2024-12-19 19:36:11 +00:00
Added files for windows heap widget and made Cutter compile with new rizin branch
This commit is contained in:
parent
a38d77c969
commit
0de63ffb34
2
rizin
2
rizin
@ -1 +1 @@
|
|||||||
Subproject commit 254c5119e3563d05d02665cabbcba003c921cee8
|
Subproject commit e7f2c2a4305ff75bc3d4682a29c58bd12e73ee2a
|
@ -147,6 +147,7 @@ set(SOURCES
|
|||||||
dialogs/GlibcHeapBinsDialog.cpp
|
dialogs/GlibcHeapBinsDialog.cpp
|
||||||
widgets/HeapBinsGraphView.cpp
|
widgets/HeapBinsGraphView.cpp
|
||||||
dialogs/ArenaInfoDialog.cpp
|
dialogs/ArenaInfoDialog.cpp
|
||||||
|
widgets/WindowsHeapWidget.cpp
|
||||||
)
|
)
|
||||||
set(HEADER_FILES
|
set(HEADER_FILES
|
||||||
core/Cutter.h
|
core/Cutter.h
|
||||||
@ -306,6 +307,7 @@ set(HEADER_FILES
|
|||||||
dialogs/GlibcHeapBinsDialog.h
|
dialogs/GlibcHeapBinsDialog.h
|
||||||
widgets/HeapBinsGraphView.h
|
widgets/HeapBinsGraphView.h
|
||||||
dialogs/ArenaInfoDialog.h
|
dialogs/ArenaInfoDialog.h
|
||||||
|
widgets/WindowsHeapWidget.h
|
||||||
)
|
)
|
||||||
set(UI_FILES
|
set(UI_FILES
|
||||||
dialogs/AboutDialog.ui
|
dialogs/AboutDialog.ui
|
||||||
@ -377,6 +379,7 @@ set(UI_FILES
|
|||||||
widgets/GlibcHeapWidget.ui
|
widgets/GlibcHeapWidget.ui
|
||||||
dialogs/GlibcHeapBinsDialog.ui
|
dialogs/GlibcHeapBinsDialog.ui
|
||||||
dialogs/ArenaInfoDialog.ui
|
dialogs/ArenaInfoDialog.ui
|
||||||
|
widgets/WindowsHeapWidget.ui
|
||||||
)
|
)
|
||||||
set(QRC_FILES
|
set(QRC_FILES
|
||||||
resources.qrc
|
resources.qrc
|
||||||
|
@ -3616,22 +3616,12 @@ QString CutterCore::addTypes(const char *str)
|
|||||||
{
|
{
|
||||||
CORE_LOCK();
|
CORE_LOCK();
|
||||||
char *error_msg = nullptr;
|
char *error_msg = nullptr;
|
||||||
char *parsed = rz_type_parse_c_string(core->analysis->typedb, str, &error_msg);
|
int result = rz_type_parse_string(core->analysis->typedb, str, &error_msg);
|
||||||
|
// TODO fix adding and parsing types
|
||||||
QString error;
|
QString error;
|
||||||
|
|
||||||
if (!parsed) {
|
if (result && error_msg) {
|
||||||
if (error_msg) {
|
error = QString(error_msg);
|
||||||
error = error_msg;
|
|
||||||
rz_mem_free(error_msg);
|
|
||||||
}
|
|
||||||
return error;
|
|
||||||
}
|
|
||||||
|
|
||||||
rz_type_db_save_parsed_type(core->analysis->typedb, parsed);
|
|
||||||
rz_mem_free(parsed);
|
|
||||||
|
|
||||||
if (error_msg) {
|
|
||||||
error = error_msg;
|
|
||||||
rz_mem_free(error_msg);
|
rz_mem_free(error_msg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
14
src/widgets/WindowsHeapWidget.cpp
Normal file
14
src/widgets/WindowsHeapWidget.cpp
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
#include "WindowsHeapWidget.h"
|
||||||
|
#include "ui_WindowsHeapWidget.h"
|
||||||
|
|
||||||
|
WindowsHeapWidget::WindowsHeapWidget(QWidget *parent) :
|
||||||
|
QWidget(parent),
|
||||||
|
ui(new Ui::WindowsHeapWidget)
|
||||||
|
{
|
||||||
|
ui->setupUi(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
WindowsHeapWidget::~WindowsHeapWidget()
|
||||||
|
{
|
||||||
|
delete ui;
|
||||||
|
}
|
22
src/widgets/WindowsHeapWidget.h
Normal file
22
src/widgets/WindowsHeapWidget.h
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
#ifndef WINDOWSHEAPWIDGET_H
|
||||||
|
#define WINDOWSHEAPWIDGET_H
|
||||||
|
|
||||||
|
#include <QWidget>
|
||||||
|
|
||||||
|
namespace Ui {
|
||||||
|
class WindowsHeapWidget;
|
||||||
|
}
|
||||||
|
|
||||||
|
class WindowsHeapWidget : public QWidget
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit WindowsHeapWidget(QWidget *parent = nullptr);
|
||||||
|
~WindowsHeapWidget();
|
||||||
|
|
||||||
|
private:
|
||||||
|
Ui::WindowsHeapWidget *ui;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // WINDOWSHEAPWIDGET_H
|
21
src/widgets/WindowsHeapWidget.ui
Normal file
21
src/widgets/WindowsHeapWidget.ui
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
<ui version="4.0">
|
||||||
|
<author/>
|
||||||
|
<comment/>
|
||||||
|
<exportmacro/>
|
||||||
|
<class>WindowsHeapWidget</class>
|
||||||
|
<widget class="QWidget" name="WindowsHeapWidget">
|
||||||
|
<property name="geometry">
|
||||||
|
<rect>
|
||||||
|
<x>0</x>
|
||||||
|
<y>0</y>
|
||||||
|
<width>400</width>
|
||||||
|
<height>300</height>
|
||||||
|
</rect>
|
||||||
|
</property>
|
||||||
|
<property name="windowTitle">
|
||||||
|
<string>Form</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
<pixmapfunction/>
|
||||||
|
<connections/>
|
||||||
|
</ui>
|
Loading…
Reference in New Issue
Block a user