artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a257dd0
)
pledge "stdio" after opening files, code is very similar to mkuboot
author
deraadt
<deraadt@openbsd.org>
Mon, 12 Oct 2015 07:45:48 +0000
(07:45 +0000)
committer
deraadt
<deraadt@openbsd.org>
Mon, 12 Oct 2015 07:45:48 +0000
(07:45 +0000)
usr.sbin/mksuncd/mksuncd.c
patch
|
blob
|
history
diff --git
a/usr.sbin/mksuncd/mksuncd.c
b/usr.sbin/mksuncd/mksuncd.c
index
75428c3
..
dc6becb
100644
(file)
--- a/
usr.sbin/mksuncd/mksuncd.c
+++ b/
usr.sbin/mksuncd/mksuncd.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: mksuncd.c,v 1.
2 2010/02/25 17:15:42
deraadt Exp $ */
+/* $OpenBSD: mksuncd.c,v 1.
3 2015/10/12 07:45:48
deraadt Exp $ */
/*
* Copyright (c) 2001 Jason L. Wright (jason@thought.net)
@@
-225,6
+225,9
@@
main(int argc, char **argv)
if (of == -1)
err(1, "open");
+ if (pledge("stdio", NULL) == -1)
+ err(1, "pledge");
+
if (get_label(bf, &sl))
return (1);