UF 0.10.4.1

- solved a problem with left on empty QByteArray
This commit is contained in:
Nikolaj Schlej 2015-12-13 16:34:56 +01:00
parent 108a40a31c
commit d1add47500
2 changed files with 4 additions and 2 deletions

View File

@ -91,7 +91,9 @@ STATUS UEFIFind::find(const UINT8 mode, const bool count, const QString & hexPat
QPair<QModelIndex, QModelIndex> indexes; QPair<QModelIndex, QModelIndex> indexes;
Q_FOREACH(indexes, files) { Q_FOREACH(indexes, files) {
QByteArray data = model->header(indexes.first).left(16); QByteArray data(16, '\x00');
if (!model->hasEmptyHeader(indexes.first))
data = model->header(indexes.first).left(16);
result.append(guidToQString((const UINT8*)data.constData())); result.append(guidToQString((const UINT8*)data.constData()));
// Special case of freeform subtype GUID files // Special case of freeform subtype GUID files

View File

@ -148,7 +148,7 @@ int main(int argc, char *argv[])
return ERR_SUCCESS; return ERR_SUCCESS;
} }
else { else {
std::cout << "UEFIFind 0.10.4" << std::endl << std::endl << std::cout << "UEFIFind 0.10.4.1" << std::endl << std::endl <<
"Usage: uefifind {header | body | all} {list | count} pattern imagefile" << std::endl << "Usage: uefifind {header | body | all} {list | count} pattern imagefile" << std::endl <<
" or uefifind file patternsfile imagefile" << std::endl; " or uefifind file patternsfile imagefile" << std::endl;
return ERR_INVALID_PARAMETER; return ERR_INVALID_PARAMETER;