Clean up handling of nonexistent symbol tables
This commit is contained in:
parent
419fa6a2ab
commit
a3b1178fd3
@ -69,7 +69,7 @@ fn main() -> Result<(), anyhow::Error> {
|
||||
let mut symbol_tables = SymbolTables::new();
|
||||
if let Some(initial_tables) = config.symbol_tables {
|
||||
for path in initial_tables {
|
||||
symbol_tables.load_table(path, true).unwrap();
|
||||
symbol_tables.load_table(path, true)?;
|
||||
}
|
||||
}
|
||||
Repl::<_, anyhow::Error>::new(EmuState {
|
||||
|
@ -27,7 +27,7 @@ impl SymbolTable {
|
||||
let mut file = elf::File::open_stream(&mut cached_reader)?;
|
||||
let (symtab, symstrtab) = file
|
||||
.symbol_table()?
|
||||
.ok_or_else(|| anyhow!("No symbol table in file"))?;
|
||||
.ok_or_else(|| anyhow!("No symbol table in {}", path))?;
|
||||
let symbols = symtab
|
||||
.iter()
|
||||
.skip(1)
|
||||
|
Loading…
Reference in New Issue
Block a user