is_bad_linker_command() ignores LC_REQ_DYLD
https://github.com/upx/upx/issues/606 modified: p_mach.cpp
This commit is contained in:
committed by
Markus F.X.J. Oberhumer
parent
65707900bc
commit
1e8f1f49d0
@@ -187,6 +187,7 @@ static int is_bad_linker_command(
|
|||||||
unsigned cmd, unsigned cmdsize,
|
unsigned cmd, unsigned cmdsize,
|
||||||
unsigned headway, unsigned lc_seg, unsigned szAddr)
|
unsigned headway, unsigned lc_seg, unsigned szAddr)
|
||||||
{
|
{
|
||||||
|
cmd &= ~LC_REQ_DYLD;
|
||||||
return !cmd // there is no LC_ cmd 0
|
return !cmd // there is no LC_ cmd 0
|
||||||
|| sizeof(lc_cmd_size) <= cmd // beyond table of known sizes
|
|| sizeof(lc_cmd_size) <= cmd // beyond table of known sizes
|
||||||
|| !lc_cmd_size[cmd] // obsolete, or proper size not known to us
|
|| !lc_cmd_size[cmd] // obsolete, or proper size not known to us
|
||||||
|
|||||||
Reference in New Issue
Block a user