artulab
projects
/
openbsd
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0c3ba0c
)
Add missing mode argument to open(2) with O_CREAT.
author
visa
<visa@openbsd.org>
Wed, 2 Feb 2022 13:22:10 +0000
(13:22 +0000)
committer
visa
<visa@openbsd.org>
Wed, 2 Feb 2022 13:22:10 +0000
(13:22 +0000)
usr.sbin/installboot/util.c
patch
|
blob
|
history
diff --git
a/usr.sbin/installboot/util.c
b/usr.sbin/installboot/util.c
index
ba5ee2f
..
0ffd5e7
100644
(file)
--- a/
usr.sbin/installboot/util.c
+++ b/
usr.sbin/installboot/util.c
@@
-1,4
+1,4
@@
-/* $OpenBSD: util.c,v 1.1
4 2019/07/03 03:24:03 deraadt Exp $
*/
+/* $OpenBSD: util.c,v 1.1
5 2022/02/02 13:22:10 visa Exp $
*/
/*
* Copyright (c) 2014 Joel Sing <jsing@openbsd.org>
@@
-52,7
+52,7
@@
filecopy(const char *srcfile, const char *dstfile)
}
sz = sb.st_size;
- dfd = open(dstfile, O_WRONLY|O_CREAT);
+ dfd = open(dstfile, O_WRONLY|O_CREAT
, S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH
);
if (dfd == -1) {
warn("open %s", dstfile);
return (-1);