diff --git a/src/main.rs b/src/main.rs index d16ea6a..6bdd31e 100644 --- a/src/main.rs +++ b/src/main.rs @@ -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 { diff --git a/src/symbol_table.rs b/src/symbol_table.rs index 2c381a9..019f313 100644 --- a/src/symbol_table.rs +++ b/src/symbol_table.rs @@ -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)