Make the "wat2wasm" error message not panic.

This commit is contained in:
Dan Gohman
2017-10-03 12:20:37 -07:00
parent cad7e50106
commit 324a395a95

View File

@@ -163,8 +163,7 @@ fn handle_module(args: &Args, path: PathBuf, name: &str, isa: &TargetIsa) -> Res
return Err(String::from("wat2wasm not found"));
} else {
return Err(String::from(e.description()));
})
.unwrap();
})?;
match read_wasm_file(file_path) {
Ok(data) => data,
Err(err) => {