diff options
| author | Linus Färnstrand <linus@mullvad.net> | 2017-09-06 15:01:35 +0200 |
|---|---|---|
| committer | Linus Färnstrand <linus@mullvad.net> | 2017-09-06 15:38:12 +0200 |
| commit | ef09c3d7fc60b80a4f1a6136e181aad6777ba4ee (patch) | |
| tree | 1e52ddb51b50dc396f27e21a5ce7dc68256c615e | |
| parent | df4620c74a958260a1618c6f95697488d84fb90e (diff) | |
| download | mullvadvpn-ef09c3d7fc60b80a4f1a6136e181aad6777ba4ee.tar.xz mullvadvpn-ef09c3d7fc60b80a4f1a6136e181aad6777ba4ee.zip | |
Run rustfmt
| -rw-r--r-- | talpid-core/src/mktemp.rs | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/talpid-core/src/mktemp.rs b/talpid-core/src/mktemp.rs index 7c0cc11b49..e8ba33c3c5 100644 --- a/talpid-core/src/mktemp.rs +++ b/talpid-core/src/mktemp.rs @@ -1,7 +1,7 @@ use std::env; -use std::path::{Path, PathBuf}; -use std::io; use std::fs; +use std::io; +use std::path::{Path, PathBuf}; use uuid::Uuid; @@ -13,9 +13,7 @@ pub struct TempFile { impl TempFile { /// Create a new unique `TempFile`. The file will not exist after this. pub fn new() -> Self { - TempFile { - path: generate_path(), - } + TempFile { path: generate_path() } } pub fn to_path_buf(&self) -> PathBuf { @@ -33,7 +31,11 @@ impl Drop for TempFile { fn drop(&mut self) { if let Err(e) = fs::remove_file(&self.path) { if e.kind() != io::ErrorKind::NotFound { - error!("Unable to remove temp file {}: {:?}", self.path.to_string_lossy(), e); + error!( + "Unable to remove temp file {}: {:?}", + self.path.to_string_lossy(), + e + ); } } } |
