fixed a nasty relocation handling error which could produce broken
compressed files committer: ml1050 <ml1050> 1126865811 +0000
This commit is contained in:
parent
0337bdb9fd
commit
eb6c51426a
@ -293,7 +293,9 @@ unsigned optimize_relocs(upx_byte *b, const unsigned size,
|
||||
{
|
||||
addr = get_le32(relocs+4*i);
|
||||
//printf ("%x\n",es*16+di);
|
||||
if (addr - es*16 > 0xfffe)
|
||||
if ((addr - es*16 > 0xfffe)
|
||||
|| (i == nrelocs - 1 && addr - es * 16 > 0xff00)
|
||||
)
|
||||
{
|
||||
// segment change
|
||||
t = 1+(0xffff-di)/254;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user