pub fn symbols(&self) -> Vec<Symbol> {
        let elf = self.elf();
        let mut symbols = Vec::new();
        for sym in elf.dynsyms.iter() {
            if sym.st_value == 0 {
                continue;
            }
            symbols.push(Symbol::new(
                &elf.dynstrtab[sym.st_name],
                sym.st_value + self.base_address(),
            ));
        }

        for sym in elf.syms.iter() {
            if sym.st_value == 0 {
                continue;
            }
            symbols.push(Symbol::new(
                &elf.strtab[sym.st_name],
                sym.st_value + self.base_address(),
            ));
        }

        for rel in elf.pltrelocs.iter() {
            let sym = match elf.dynsyms.get(rel.r_sym) {
                Some(sym) => sym,
                None => continue,
            };

            let name = &elf.dynstrtab[sym.st_name];
            symbols.push(Symbol::new(name, rel.r_offset));
        }

        symbols.sort();
        symbols.dedup();
        symbols
    }
/// Return all symbols for this Elf
Return all symbols for this Elf
Return all symbols for this Elf
pub fn symbols(&self) -> Vec<Symbol> {
        let elf = self.elf();
        let mut symbols = Vec::new();
        for sym in elf.dynsyms.iter() {
            if sym.st_value == 0 {
                continue;
            }
            symbols.push(Symbol::new(
                &elf.dynstrtab[sym.st_name],
                sym.st_value + self.base_address(),
            ));
        }
        for sym in elf.syms.iter() {
            if sym.st_value == 0 {
                continue;
            }
            symbols.push(Symbol::new(
                &elf.strtab[sym.st_name],
                sym.st_value + self.base_address(),
            ));
        }
        for rel in elf.pltrelocs.iter() {
            let sym = match elf.dynsyms.get(rel.r_sym) {
                Some(sym) => sym,
                None => continue,
            };
            let name = &elf.dynstrtab[sym.st_name];
            symbols.push(Symbol::new(name, rel.r_offset));
        }
        symbols.sort();
        symbols.dedup();
        symbols
    }
pub fn symbols ( & self ) -> Vec < Symbol > { let elf = self . elf ( ) ; let mut symbols = Vec :: new ( ) ; for sym in elf . dynsyms . iter ( ) { if sym . st_value == 0 { continue ; } symbols . push ( Symbol :: new ( & elf . dynstrtab [ sym . st_name ] , sym . st_value + self . base_address ( ) , ) ) ; } for sym in elf . syms . iter ( ) { if sym . st_value == 0 { continue ; } symbols . push ( Symbol :: new ( & elf . strtab [ sym . st_name ] , sym . st_value + self . base_address ( ) , ) ) ; } for rel in elf . pltrelocs . iter ( ) { let sym = match elf . dynsyms . get ( rel . r_sym ) { Some ( sym ) => sym , None => continue , } ; let name = & elf . dynstrtab [ sym . st_name ] ; symbols . push ( Symbol :: new ( name , rel . r_offset ) ) ; } symbols . sort ( ) ; symbols . dedup ( ) ; symbols }
Return all symbols for this Elf
Return all symbols for this Elf
&self
&self