From: Maximiliano Sandoval <m.sandoval@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] [PATCH proxmox 2/9] daemon: set_var is now unsafe
Date: Tue, 4 Mar 2025 15:40:44 +0100 [thread overview]
Message-ID: <20250304144051.585163-2-m.sandoval@proxmox.com> (raw)
In-Reply-To: <20250304144051.585163-1-m.sandoval@proxmox.com>
In edition 2024 set_var is unsafe.
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
proxmox-daemon/src/server.rs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/proxmox-daemon/src/server.rs b/proxmox-daemon/src/server.rs
index 7cf5ea06..670e3c3b 100644
--- a/proxmox-daemon/src/server.rs
+++ b/proxmox-daemon/src/server.rs
@@ -79,7 +79,7 @@ impl Reloader {
fn pre_exec(self) -> Result<(), Error> {
for item in self.pre_exec {
- std::env::set_var(item.name, (item.store_fn)()?);
+ unsafe { std::env::set_var(item.name, (item.store_fn)()?) };
}
Ok(())
}
--
2.39.5
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
next prev parent reply other threads:[~2025-03-04 14:41 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-04 14:40 [pbs-devel] [PATCH proxmox 1/9] mark extern C blocks as unsafe Maximiliano Sandoval
2025-03-04 14:40 ` Maximiliano Sandoval [this message]
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 3/9] mark blocks inside unsafe fns unsafe Maximiliano Sandoval
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 4/9] broadcast_future: accommodate to edition 2024 changes to RPIT Maximiliano Sandoval
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 5/9] procfs: add variable bindings for std::fs::read Maximiliano Sandoval
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 6/9] port to edition 2024 Maximiliano Sandoval
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 7/9] run rustfmt with " Maximiliano Sandoval
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 8/9] run cargo clippy --fix Maximiliano Sandoval
2025-03-04 14:40 ` [pbs-devel] [PATCH proxmox 9/9] manual clippy fixes Maximiliano Sandoval
2025-03-19 11:34 ` [pbs-devel] partially-applied: [PATCH proxmox 1/9] mark extern C blocks as unsafe Wolfgang Bumiller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250304144051.585163-2-m.sandoval@proxmox.com \
--to=m.sandoval@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.