def get(filename):
    is_pe = pe.is_pe(filename)
    is_elf = elf.is_elf(filename)
    if is_pe:
            return pe.get(filename) 
    elif is_elf:
        return elf.get(filename)
Exemple #2
0
def is_obj(path):
    assert sys.platform != 'win32'
    return bool((sys.platform == 'linux2' and elf.is_elf(path)) or
                (sys.platform == 'darwin' and macho.is_macho(path)))