aboutsummaryrefslogtreecommitdiffstats
path: root/guts/mkstemp.c
diff options
context:
space:
mode:
Diffstat (limited to 'guts/mkstemp.c')
-rw-r--r--guts/mkstemp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/guts/mkstemp.c b/guts/mkstemp.c
index a8f5915..ee8c742 100644
--- a/guts/mkstemp.c
+++ b/guts/mkstemp.c
@@ -27,12 +27,12 @@
save_errno = errno;
if (real___fxstat64(_STAT_VER, rc, &buf) != -1) {
- pseudo_client_op(OP_CREAT, -1, -1, tmp_template, &buf);
- pseudo_client_op(OP_OPEN, rc, -1, tmp_template, &buf);
+ pseudo_client_op(OP_CREAT, 0, -1, -1, tmp_template, &buf);
+ pseudo_client_op(OP_OPEN, PSA_READ | PSA_WRITE, rc, -1, tmp_template, &buf);
} else {
pseudo_debug(1, "mkstemp (fd %d) succeeded, but fstat failed (%s).\n",
rc, strerror(errno));
- pseudo_client_op(OP_OPEN, rc, -1, tmp_template, 0);
+ pseudo_client_op(OP_OPEN, PSA_READ | PSA_WRITE, rc, -1, tmp_template, 0);
}
errno = save_errno;
}