Set Analysis configuration before executing Analysis commands (#1048)

* Set analysis configurations defined by the user before executing the
analysis commands (fixes #1047)

* Remove (probably) unnecessary lines which reset settings determined by
the user
This commit is contained in:
Itay Cohen 2019-01-02 15:40:46 +02:00 committed by GitHub
parent 8e76a9aca5
commit 4505d187c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 13 deletions

View File

@ -378,10 +378,6 @@ void MainWindow::openProject(const QString &project_name)
void MainWindow::finalizeOpen()
{
core->getOpcodes();
// Override any incorrect setting saved in the project
core->setSettings();
core->updateSeek();
core->message(tr(" > Populating UI"));
refreshAll();

View File

@ -178,6 +178,16 @@ QList<QString> InitialOptionsDialog::getSelectedAdvancedAnalCmds()
{
QList<QString> advanced = QList<QString>();
if (ui->analSlider->value() == 3) {
// Enable analysis configurations before executing analysis commands
if (ui->jmptbl->isChecked()) {
advanced << "e! anal.jmptbl";
}
if (ui->pushret->isChecked()) {
advanced << "e! anal.pushret";
}
if (ui->hasnext->isChecked()) {
advanced << "e! anal.hasnext";
}
if (ui->aa_symbols->isChecked()) {
advanced << "aa";
}
@ -208,15 +218,6 @@ QList<QString> InitialOptionsDialog::getSelectedAdvancedAnalCmds()
if (ui->aap_preludes->isChecked()) {
advanced << "aap";
}
if (ui->jmptbl->isChecked()) {
advanced << "e! anal.jmptbl";
}
if (ui->pushret->isChecked()) {
advanced << "e! anal.pushret";
}
if (ui->hasnext->isChecked()) {
advanced << "e! anal.hasnext";
}
}
return advanced;
}