Adjust gitignore, fix clippy lints (#257)

* Add .vscode to .gitignore
* Fix clippy lints
This commit is contained in:
Jeff Hiner 2022-05-11 12:23:07 -06:00 committed by GitHub
parent 28e0df8263
commit 7b6afadb0a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 3 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
/target
**/*.rs.bk
.vscode/

View File

@ -153,7 +153,7 @@ fn main() {
use_multi_queue: !matches.is_present("disable-multi-queue"),
};
let mut device_handle: DeviceHandle = match DeviceHandle::new(&tun_name, config) {
let mut device_handle: DeviceHandle = match DeviceHandle::new(tun_name, config) {
Ok(d) => d,
Err(e) => {
// Notify parent that tunnel initialization failed

View File

@ -32,7 +32,7 @@ pub fn get_saved_ids() -> Result<(uid_t, gid_t), Error> {
// Saved user ID
let saved_uid = unsafe { (*userinfo).pw_uid };
return Ok((saved_uid, saved_gid));
Ok((saved_uid, saved_gid))
}
}

View File

@ -325,7 +325,7 @@ impl Device {
)
.unwrap();
let peer = Peer::new(tunn, next_index, endpoint, &allowed_ips, preshared_key);
let peer = Peer::new(tunn, next_index, endpoint, allowed_ips, preshared_key);
let peer = Arc::new(peer);
self.peers.insert(pub_key, Arc::clone(&peer));