summaryrefslogtreecommitdiffstats
path: root/src/log.rs
diff options
context:
space:
mode:
authorqkzk <qu3nt1n@gmail.com>2022-11-05 21:09:33 +0100
committerqkzk <qu3nt1n@gmail.com>2022-11-05 21:09:33 +0100
commit8315ff1bb852e9d29f275e5c3568eaefa25998c5 (patch)
tree5f07195c4694847db9618d808fc6155bbc3b057e /src/log.rs
parent2fe45b9ffd8d96c0c5565fddb8171574c8e7d4b3 (diff)
fix existing log path makes the app crashlogs
Diffstat (limited to 'src/log.rs')
-rw-r--r--src/log.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/log.rs b/src/log.rs
index b428f10..0938eb0 100644
--- a/src/log.rs
+++ b/src/log.rs
@@ -26,8 +26,8 @@ pub fn set_logger() -> FmResult<Handle> {
let compound_policy =
CompoundPolicy::new(Box::new(size_trigger), Box::new(fixed_window_roller));
let log_path = shellexpand::tilde(LOG_PATH).to_string();
- std::fs::create_dir_all(&log_path)?;
-
+ // Don't propagate the error with ? since it crashes the application.
+ let _ = std::fs::create_dir_all(&log_path);
// Log Trace level output to file where trace is the default level
// and the programmatically specified level to stderr.
let config = Config::builder()