summaryrefslogtreecommitdiff
path: root/util/nvmutil/lib/state.c
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2026-03-22 19:49:50 +0000
committerLeah Rowe <leah@libreboot.org>2026-03-22 20:01:11 +0000
commita505cb261a22194c9c7f4f1a3426d3ce45a3bdf2 (patch)
tree49c19d4d1ebaebd2946c5300aef9b8279c354166 /util/nvmutil/lib/state.c
parentb8ababa2beb1b5466b6ba2062e52be36a73d654e (diff)
WIP: remove local mode in mkhtemp + cleanup
bloat unveil can get pledged Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'util/nvmutil/lib/state.c')
-rw-r--r--util/nvmutil/lib/state.c13
1 files changed, 2 insertions, 11 deletions
diff --git a/util/nvmutil/lib/state.c b/util/nvmutil/lib/state.c
index 9869bb14..836c6bc7 100644
--- a/util/nvmutil/lib/state.c
+++ b/util/nvmutil/lib/state.c
@@ -89,8 +89,6 @@ xstart(int argc, char *argv[])
};
- struct xstate *x = &us;
-
if (!first_run) {
if (pre_init)
err_no_cleanup(ECANCELED,
@@ -114,17 +112,10 @@ xstart(int argc, char *argv[])
us.argv0 = argv[0];
us.f.fname = argv[1];
-#if defined(__OpenBSD__) && defined(OpenBSD) && \
- (OpenBSD) >= 604
- /* can only use local tmp on openbsd, due to unveil */
- us.f.tname = new_tmpfile(&us.f.tmp_fd, 1, NULL);
-#else
- // TODO: new_tmplate (do for above too)
- us.f.tname = new_tmpfile(&us.f.tmp_fd, 0, NULL); // TODO: NULL BAD!
-#endif
+ us.f.tname = new_tmpfile(&us.f.tmp_fd);
/* parse user command */
-// TODO: CHECK ACCESSES VIA xstatus()
+/* TODO: CHECK ACCESSES VIA xstatus() */
set_cmd(argc, argv);
set_cmd_args(argc, argv);