aboutsummaryrefslogtreecommitdiff
path: root/crates/xa65
diff options
context:
space:
mode:
Diffstat (limited to 'crates/xa65')
-rw-r--r--crates/xa65/src/main.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/xa65/src/main.rs b/crates/xa65/src/main.rs
index 96c5582..59bdc7d 100644
--- a/crates/xa65/src/main.rs
+++ b/crates/xa65/src/main.rs
@@ -169,7 +169,7 @@ fn get_binaries(nasm_name: String) -> Result<(PathBuf, PathBuf), String> {
fn temporary_dir() -> PathBuf {
let tmp = &std::env::temp_dir();
let paths = std::fs::read_dir(tmp).unwrap();
- let name = format!("xa65-{}", paths.count());
+ let name = format!("xa65-{}", paths.count() + 1);
tmp.join(name)
}
@@ -237,7 +237,7 @@ fn main() {
// as an intermediate step.
let dir = temporary_dir();
if let Err(e) = std::fs::create_dir(&dir) {
- die(e.to_string());
+ die(format!("could not create temporary directory: {}", e));
return;
}