mirror of
https://github.com/wez/wezterm.git
synced 2024-11-27 12:23:46 +03:00
move the umask setting to happen earlier
This commit is contained in:
parent
b07ed45447
commit
a8a0ad579e
@ -1,6 +1,7 @@
|
||||
// Don't create a new standard console window when launched from the windows GUI.
|
||||
#![windows_subsystem = "windows"]
|
||||
|
||||
use crate::server::listener::umask;
|
||||
use anyhow::{anyhow, bail, Context};
|
||||
use promise::spawn::block_on;
|
||||
use std::ffi::OsString;
|
||||
@ -722,6 +723,7 @@ fn run() -> anyhow::Result<()> {
|
||||
};
|
||||
pretty_env_logger::init();
|
||||
stats::Stats::init()?;
|
||||
let _saver = umask::UmaskSaver::new();
|
||||
|
||||
let opts = Opt::from_args();
|
||||
if !opts.skip_config {
|
||||
|
@ -1,6 +1,6 @@
|
||||
use crate::config::UnixDomain;
|
||||
use crate::create_user_owned_dirs;
|
||||
use crate::server::listener::{clientsession, umask};
|
||||
use crate::server::listener::clientsession;
|
||||
use crate::server::UnixListener;
|
||||
use anyhow::{anyhow, Context as _};
|
||||
use promise::spawn::spawn_into_main_thread;
|
||||
@ -45,8 +45,6 @@ fn safely_create_sock_path(unix_dom: &UnixDomain) -> anyhow::Result<UnixListener
|
||||
let sock_path = &unix_dom.socket_path();
|
||||
log::debug!("setting up {}", sock_path.display());
|
||||
|
||||
let _saver = umask::UmaskSaver::new();
|
||||
|
||||
let sock_dir = sock_path
|
||||
.parent()
|
||||
.ok_or_else(|| anyhow!("sock_path {} has no parent dir", sock_path.display()))?;
|
||||
|
@ -11,7 +11,7 @@ mod clientsession;
|
||||
mod local;
|
||||
mod ossl;
|
||||
mod pki;
|
||||
mod umask;
|
||||
pub mod umask;
|
||||
|
||||
lazy_static::lazy_static! {
|
||||
static ref PKI: pki::Pki = pki::Pki::init().expect("failed to initialize PKI");
|
||||
|
Loading…
Reference in New Issue
Block a user