deps: update nix and other dependencies
`fork` is now marked as unsafe (nix-rust/nix#1030)
This commit is contained in:

committed by
Kenny Levinsen

parent
eef821c68b
commit
e5a598298a
@@ -10,7 +10,7 @@ repository = "https://git.sr.ht/~kennylevinsen/greetd/"
|
||||
[dependencies]
|
||||
greetd_ipc = { path = "../greetd_ipc", features = ["sync-codec"]}
|
||||
inish = { path = "../inish"}
|
||||
rpassword = "4.0"
|
||||
rpassword = "5.0"
|
||||
getopts = "0.2"
|
||||
enquote = "1.0.3"
|
||||
nix = "0.17"
|
||||
nix = "0.19"
|
@@ -11,9 +11,9 @@ repository = "https://git.sr.ht/~kennylevinsen/greetd/"
|
||||
debug = []
|
||||
|
||||
[dependencies]
|
||||
nix = "0.17"
|
||||
nix = "0.19"
|
||||
pam-sys = "0.5.6"
|
||||
users = "0.9.1"
|
||||
users = "0.11.0"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
serde_json = "1.0"
|
||||
greetd_ipc = { path = "../greetd_ipc", features = ["tokio-codec"] }
|
||||
|
@@ -105,7 +105,7 @@ impl Session {
|
||||
let cur_exe = std::env::current_exe()?;
|
||||
let bin = CString::new(cur_exe.to_str().expect("unable to get current exe name"))?;
|
||||
|
||||
let child = match fork().map_err(|e| format!("unable to fork: {}", e))? {
|
||||
let child = match unsafe { fork() }.map_err(|e| format!("unable to fork: {}", e))? {
|
||||
ForkResult::Parent { child, .. } => child,
|
||||
ForkResult::Child => {
|
||||
execv(
|
||||
|
@@ -225,7 +225,7 @@ fn worker(sock: &UnixDatagram) -> Result<(), Error> {
|
||||
// PAM is weird and gets upset if you exec from the process that opened
|
||||
// the session, registering it automatically as a log-out. Thus, we must
|
||||
// exec in a new child.
|
||||
let child = match fork().map_err(|e| format!("unable to fork: {}", e))? {
|
||||
let child = match unsafe { fork() }.map_err(|e| format!("unable to fork: {}", e))? {
|
||||
ForkResult::Parent { child, .. } => child,
|
||||
ForkResult::Child => {
|
||||
// It is important that we do *not* return from here by
|
||||
|
Reference in New Issue
Block a user