Skip to content

Commit

Permalink
make clippy happy
Browse files Browse the repository at this point in the history
  • Loading branch information
zephyrchien committed Oct 16, 2024
1 parent e1ac490 commit 5a5829d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 10 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ fern = "0.6"
chrono = "0.4"

# command
clap = "4"
clap = { version = "4", features = ["string"] }
toml = "0.8"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
Expand Down
2 changes: 2 additions & 0 deletions realm_core/src/dns/mod.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#![allow(static_mut_refs)]

//! Global dns resolver.
use std::io::{Result, Error, ErrorKind};
Expand Down
10 changes: 2 additions & 8 deletions src/cmd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,10 @@ pub enum CmdInput {
}

pub fn scan() -> CmdInput {
static mut _VER: String = String::new(); // damn!
let version = format!("{} {}", VERSION, FEATURES);
let version = unsafe {
_VER = version;
_VER.as_str()
};

let ver = format!("{} {}", VERSION, FEATURES);
let app = Command::new("Realm")
.about("A high efficiency relay tool")
.version(version);
.version(ver);

let app = app
.disable_help_flag(true)
Expand Down
1 change: 0 additions & 1 deletion src/conf/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ pub use legacy::LegacyConf;
/// cmd | file => NetConf
/// \
/// cmd | file => EndpointConf => { [local, remote, conn_opts] }
pub trait Config {
type Output;

Expand Down

0 comments on commit 5a5829d

Please sign in to comment.