Skip to content

Commit

Permalink
Remove NOTIFY_FD after reading it
Browse files Browse the repository at this point in the history
  • Loading branch information
YaLTeR committed Mar 6, 2024
1 parent 3ee2db7 commit 1a784e6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -323,6 +323,7 @@ fn notify_fd() -> anyhow::Result<()> {
Err(env::VarError::NotPresent) => return Ok(()),
Err(err) => return Err(err.into()),
};
env::remove_var("NOTIFY_FD");
let mut notif = unsafe { File::from_raw_fd(fd) };
notif.write_all(b"READY=1\n")?;
Ok(())
Expand Down

0 comments on commit 1a784e6

Please sign in to comment.