* sysdeps/posix/tempname.c (__gen_tempname): Correct flag selection.
This commit is contained in:
Ulrich Drepper 2008-03-30 03:30:38 +00:00
parent 1e489af957
commit e8a3212650
2 changed files with 4 additions and 1 deletions

View File

@ -1,5 +1,8 @@
2008-03-29 Ulrich Drepper <drepper@redhat.com> 2008-03-29 Ulrich Drepper <drepper@redhat.com>
[BZ #5939]
* sysdeps/posix/tempname.c (__gen_tempname): Correct flag selection.
* posix/getopt.c (_getopt_internal_r): Remove old POSIX-demanded * posix/getopt.c (_getopt_internal_r): Remove old POSIX-demanded
error message. POSIX today does not require the messages to be in error message. POSIX today does not require the messages to be in
a specific form. Suggested by Jim Meyering <jim@meyering.net>. a specific form. Suggested by Jim Meyering <jim@meyering.net>.

View File

@ -297,7 +297,7 @@ __gen_tempname (char *tmpl, int flags, int kind)
{ {
case __GT_FILE: case __GT_FILE:
fd = __open (tmpl, fd = __open (tmpl,
(flags & ~ACCESSPERMS) (flags & ~O_ACCMODE)
| O_RDWR | O_CREAT | O_EXCL, S_IRUSR | S_IWUSR); | O_RDWR | O_CREAT | O_EXCL, S_IRUSR | S_IWUSR);
break; break;