summaryrefslogtreecommitdiff
path: root/libiberty/mkstemps.c
diff options
context:
space:
mode:
authorkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>2002-01-15 14:34:56 +0000
committerkenner <kenner@138bc75d-0d04-0410-961f-82ee72b054a4>2002-01-15 14:34:56 +0000
commitb4eac72f6d0794f0281c90fceee0f9dd8203ce6b (patch)
tree2d3741d98db375c1bfe9eb45b48d99e89bbf5b04 /libiberty/mkstemps.c
parent080a7bc955c525c9355947a6fd868191e6e8774d (diff)
downloadgcc-b4eac72f6d0794f0281c90fceee0f9dd8203ce6b.tar.gz
* libiberty/mkstemps.c (mkstemps): On VMS, open temp file with option
that causes it to be deleted when closed. * gcc/gcc.c (delete_if_ordinary): Backout previous change. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@48872 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libiberty/mkstemps.c')
-rw-r--r--libiberty/mkstemps.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libiberty/mkstemps.c b/libiberty/mkstemps.c
index 8fe5784f189..1f6600a15b9 100644
--- a/libiberty/mkstemps.c
+++ b/libiberty/mkstemps.c
@@ -121,7 +121,11 @@ mkstemps (template, suffix_len)
v /= 62;
XXXXXX[5] = letters[v % 62];
+#ifdef VMS
+ fd = open (template, O_RDWR|O_CREAT|O_EXCL, 0600, "fop=tmd");
+#else
fd = open (template, O_RDWR|O_CREAT|O_EXCL, 0600);
+#endif
if (fd >= 0)
/* The file does not exist. */
return fd;