diff --git a/UEFITool/ffsops.cpp b/UEFITool/ffsops.cpp index 53ac90b..6d3b70f 100644 --- a/UEFITool/ffsops.cpp +++ b/UEFITool/ffsops.cpp @@ -85,7 +85,7 @@ STATUS FfsOperations::extract(const QModelIndex & index, QString & name, QByteAr // Handle file tail if (model->type(index) == Types::File) { if (pdata.file.hasTail) - extracted.append(pdata.file.tail); + extracted.append(pdata.file.tailArray[0]).append(pdata.file.tailArray[1]); } } else if (mode == EXTRACT_MODE_BODY) { diff --git a/common/parsingdata.h b/common/parsingdata.h index 5ee9eaa..818891f 100644 --- a/common/parsingdata.h +++ b/common/parsingdata.h @@ -43,7 +43,10 @@ typedef struct _VOLUME_PARSING_DATA { //} FREE_SPACE_PARSING_DATA; typedef struct _FILE_PARSING_DATA { - UINT16 tail; + union { + UINT8 tailArray[2]; + UINT16 tail; + }; BOOLEAN hasTail; } FILE_PARSING_DATA;