Fix non-writable tempfile(), "rw" --> "w+", found by Westermo

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2017-06-18 18:18:08 +02:00
1 parent 6ec2a31042
commit fe82ab953c
1 file changed
+1 -1
+1 -1
View File
@@ -45,7 +45,7 @@ FILE *tempfile(void)
if (-1 == fd)
return NULL;
return fdopen(fd, "rw");
return fdopen(fd, "w+");
#else
return tmpfile(); /* Fallback on older GLIBC/Linux and actual UNIX systems */
#endif