Skip to content

Commit

Permalink
Merge pull request #33 from ukrkyi/master
Browse files Browse the repository at this point in the history
Fix of localized systems debug problem
  • Loading branch information
Dman95 committed May 26, 2015
2 parents f1f8e1c + 1f487af commit e8c80f3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions debugger.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,11 @@ Debugger::Debugger(QTextEdit *tEdit, const QString &path, QString tmp, Assembler

//determine entry point
QProcess objdumpProcess;
QProcessEnvironment objdumpEnvironment = QProcessEnvironment::systemEnvironment();
QStringList objdumpArguments;
objdumpArguments << "-f" << path;
objdumpEnvironment.insert("LC_MESSAGES", "en_US");
objdumpProcess.setProcessEnvironment(objdumpEnvironment);
objdumpProcess.start(objdump, objdumpArguments);
objdumpProcess.waitForFinished();
QString objdumpResult = QString(objdumpProcess.readAllStandardOutput());
Expand All @@ -92,6 +95,7 @@ Debugger::Debugger(QTextEdit *tEdit, const QString &path, QString tmp, Assembler
objdumpResult = objdumpResult.mid(index + startAddress.length());
entryPoint = objdumpResult.toLongLong(0, 16);


QStringList arguments;
arguments << path;

Expand Down
1 change: 1 addition & 0 deletions debugger.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
#define DEBUGGER_H

#include <QProcess>
#include <QProcessEnvironment>
#include <QString>
#include <QTextStream>
#include <QTextEdit>
Expand Down

0 comments on commit e8c80f3

Please sign in to comment.