in src/cache.rs [82:103]
fn read_config() -> Option<Vec<SymbolServer>> {
let home = match home_dir() {
Some(h) => h,
_ => return None,
};
let conf = home.join(".dump_syms").join("config");
if !conf.exists() {
return None;
}
let mut file = File::open(&conf)
.unwrap_or_else(|_| panic!("Unable to open the file {}", conf.to_str().unwrap()));
let mut buf = Vec::new();
file.read_to_end(&mut buf)
.unwrap_or_else(|_| panic!("Unable to read the file {}", conf.to_str().unwrap()));
let content = String::from_utf8(buf)
.unwrap_or_else(|_| panic!("Not utf-8 data in the file {}", conf.to_str().unwrap()));
read_config_from_str(&content)
}