Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
horsicq committed Dec 23, 2019
1 parent d7446b4 commit 29d356a
Show file tree
Hide file tree
Showing 2 changed files with 78 additions and 0 deletions.
72 changes: 72 additions & 0 deletions xle.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,48 @@ quint32 XLE::getImageVxdHeader_pagesize()
return nResult;
}

quint32 XLE::getImageVxdHeader_lastpagesize()
{
quint32 nResult=0;

qint64 nOffset=getImageVxdHeaderOffset();

if(nOffset!=-1)
{
nResult=read_uint32(nOffset+offsetof(XLE_DEF::IMAGE_VXD_HEADER,e32_lastpagesize));
}

return nResult;
}

quint32 XLE::getImageVxdHeader_fixupsize()
{
quint32 nResult=0;

qint64 nOffset=getImageVxdHeaderOffset();

if(nOffset!=-1)
{
nResult=read_uint32(nOffset+offsetof(XLE_DEF::IMAGE_VXD_HEADER,e32_fixupsize));
}

return nResult;
}

quint32 XLE::getImageVxdHeader_fixupsum()
{
quint32 nResult=0;

qint64 nOffset=getImageVxdHeaderOffset();

if(nOffset!=-1)
{
nResult=read_uint32(nOffset+offsetof(XLE_DEF::IMAGE_VXD_HEADER,e32_fixupsum));
}

return nResult;
}

void XLE::setImageVxdHeader_magic(quint16 value)
{
qint64 nOffset=getImageVxdHeaderOffset();
Expand Down Expand Up @@ -461,6 +503,36 @@ void XLE::setImageVxdHeader_pagesize(quint32 value)
}
}

void XLE::setImageVxdHeader_lastpagesize(quint32 value)
{
qint64 nOffset=getImageVxdHeaderOffset();

if(nOffset!=-1)
{
write_uint32(nOffset+offsetof(XLE_DEF::IMAGE_VXD_HEADER,e32_lastpagesize),value);
}
}

void XLE::setImageVxdHeader_fixupsize(quint32 value)
{
qint64 nOffset=getImageVxdHeaderOffset();

if(nOffset!=-1)
{
write_uint32(nOffset+offsetof(XLE_DEF::IMAGE_VXD_HEADER,e32_fixupsize),value);
}
}

void XLE::setImageVxdHeader_fixupsum(quint32 value)
{
qint64 nOffset=getImageVxdHeaderOffset();

if(nOffset!=-1)
{
write_uint32(nOffset+offsetof(XLE_DEF::IMAGE_VXD_HEADER,e32_fixupsum),value);
}
}

QMap<quint64, QString> XLE::getImageLEMagics()
{
QMap<quint64, QString> mapResult;
Expand Down
6 changes: 6 additions & 0 deletions xle.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ class XLE : public XMSDOS
quint32 getImageVxdHeader_stackobj();
quint32 getImageVxdHeader_esp();
quint32 getImageVxdHeader_pagesize();
quint32 getImageVxdHeader_lastpagesize();
quint32 getImageVxdHeader_fixupsize();
quint32 getImageVxdHeader_fixupsum();

void setImageVxdHeader_magic(quint16 value);
void setImageVxdHeader_border(quint8 value);
Expand All @@ -65,6 +68,9 @@ class XLE : public XMSDOS
void setImageVxdHeader_stackobj(quint32 value);
void setImageVxdHeader_esp(quint32 value);
void setImageVxdHeader_pagesize(quint32 value);
void setImageVxdHeader_lastpagesize(quint32 value);
void setImageVxdHeader_fixupsize(quint32 value);
void setImageVxdHeader_fixupsum(quint32 value);

static QMap<quint64, QString> getImageLEMagics();
static QMap<quint64, QString> getImageLEMagicsS();
Expand Down

0 comments on commit 29d356a

Please sign in to comment.