mirror of
https://github.com/zerotier/ZeroTierOne.git
synced 2025-06-08 13:33:44 +02:00
WIP it good
This commit is contained in:
parent
768ec6e710
commit
dca7bb8e85
2 changed files with 20 additions and 19 deletions
|
@ -109,25 +109,25 @@ impl<DatabaseImpl: Database> InnerProtocol for Controller<DatabaseImpl> {
|
|||
|
||||
fn handle_error<HostSystemImpl: HostSystem>(
|
||||
&self,
|
||||
source: &Arc<Peer<HostSystemImpl>>,
|
||||
source_path: &Arc<Path<HostSystemImpl>>,
|
||||
in_re_verb: u8,
|
||||
in_re_message_id: u64,
|
||||
error_code: u8,
|
||||
payload: &PacketBuffer,
|
||||
cursor: &mut usize,
|
||||
_source: &Arc<Peer<HostSystemImpl>>,
|
||||
_source_path: &Arc<Path<HostSystemImpl>>,
|
||||
_in_re_verb: u8,
|
||||
_in_re_message_id: u64,
|
||||
_error_code: u8,
|
||||
_payload: &PacketBuffer,
|
||||
_cursor: &mut usize,
|
||||
) -> PacketHandlerResult {
|
||||
PacketHandlerResult::NotHandled
|
||||
}
|
||||
|
||||
fn handle_ok<HostSystemImpl: HostSystem>(
|
||||
&self,
|
||||
source: &Arc<Peer<HostSystemImpl>>,
|
||||
source_path: &Arc<Path<HostSystemImpl>>,
|
||||
in_re_verb: u8,
|
||||
in_re_message_id: u64,
|
||||
payload: &PacketBuffer,
|
||||
cursor: &mut usize,
|
||||
_source: &Arc<Peer<HostSystemImpl>>,
|
||||
_source_path: &Arc<Path<HostSystemImpl>>,
|
||||
_in_re_verb: u8,
|
||||
_in_re_message_id: u64,
|
||||
_payload: &PacketBuffer,
|
||||
_cursor: &mut usize,
|
||||
) -> PacketHandlerResult {
|
||||
PacketHandlerResult::NotHandled
|
||||
}
|
||||
|
|
|
@ -1,11 +1,10 @@
|
|||
// (c) 2020-2022 ZeroTier, Inc. -- currently propritery pending actual release and licensing. See LICENSE.md.
|
||||
|
||||
use std::path::{Path, PathBuf};
|
||||
use std::str::FromStr;
|
||||
use std::sync::Arc;
|
||||
|
||||
use crate::localconfig::Config;
|
||||
use crate::utils::{read_limit, DEFAULT_FILE_IO_READ_LIMIT};
|
||||
use std::path::{Path, PathBuf};
|
||||
use std::str::FromStr;
|
||||
use std::sync::Arc;
|
||||
|
||||
use parking_lot::{Mutex, RwLock};
|
||||
|
||||
|
@ -46,7 +45,8 @@ impl NodeStorage for DataDir {
|
|||
}
|
||||
|
||||
fn save_node_identity(&self, id: &Identity) {
|
||||
tokio::runtime::Handle::current().block_on(async {
|
||||
/*
|
||||
tokio::runtime::Handle::current().spawn(async move {
|
||||
assert!(id.secret.is_some());
|
||||
let id_secret_str = id.to_secret_string();
|
||||
let id_public_str = id.to_string();
|
||||
|
@ -55,7 +55,8 @@ impl NodeStorage for DataDir {
|
|||
let _ = tokio::fs::write(&secret_path, id_secret_str.as_bytes()).await;
|
||||
assert!(crate::utils::fs_restrict_permissions(&secret_path));
|
||||
let _ = tokio::fs::write(self.base_path.join(IDENTITY_PUBLIC_FILENAME), id_public_str.as_bytes()).await;
|
||||
})
|
||||
});
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue