aboutsummaryrefslogtreecommitdiff
path: root/libgfortran/io/unix.c
diff options
context:
space:
mode:
authorFrancois-Xavier Coudert <coudert@clipper.ens.fr>2005-08-06 17:38:49 +0200
committerFrançois-Xavier Coudert <fxcoudert@gcc.gnu.org>2005-08-06 15:38:49 +0000
commit2c4a108eec40a96ac7c5fcb8811678c11c71c529 (patch)
tree70ec32abdfb967bc3ba2e81877fc8e0a5d6825de /libgfortran/io/unix.c
parent2f806f3b9babbbb17374ee37b37407bf136e66e7 (diff)
downloadgcc-2c4a108eec40a96ac7c5fcb8811678c11c71c529.zip
gcc-2c4a108eec40a96ac7c5fcb8811678c11c71c529.tar.gz
gcc-2c4a108eec40a96ac7c5fcb8811678c11c71c529.tar.bz2
* io/unix.c: Add O_RDWR to open() call.
From-SVN: r102811
Diffstat (limited to 'libgfortran/io/unix.c')
-rw-r--r--libgfortran/io/unix.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libgfortran/io/unix.c b/libgfortran/io/unix.c
index b35182d..56df254 100644
--- a/libgfortran/io/unix.c
+++ b/libgfortran/io/unix.c
@@ -998,7 +998,7 @@ tempfile (void)
if (mktemp (template))
do
- fd = open (template, O_CREAT | O_EXCL, S_IREAD | S_IWRITE);
+ fd = open (template, O_RDWR |O_CREAT | O_EXCL, S_IREAD | S_IWRITE);
while (!(fd == -1 && errno == EEXIST) && mktemp (template));
else
fd = -1;