mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-30 22:43:12 +03:00
Assume that O_CLOEXEC is always defined and works
This commit is contained in:
@ -45,11 +45,7 @@ _dl_sysdep_read_whole_file (const char *file, size_t *sizep, int prot)
|
||||
{
|
||||
void *result = MAP_FAILED;
|
||||
struct stat64 st;
|
||||
int flags = O_RDONLY;
|
||||
#ifdef O_CLOEXEC
|
||||
flags |= O_CLOEXEC;
|
||||
#endif
|
||||
int fd = __open (file, flags);
|
||||
int fd = __open (file, O_RDONLY | O_CLOEXEC);
|
||||
if (fd >= 0)
|
||||
{
|
||||
if (__fxstat64 (_STAT_VER, fd, &st) >= 0)
|
||||
|
Reference in New Issue
Block a user