This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch release/2.22/master updated. glibc-2.22-5-g561a9f1
- From: schwab at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 10 Aug 2015 16:22:41 -0000
- Subject: GNU C Library master sources branch release/2.22/master updated. glibc-2.22-5-g561a9f1
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".
The branch, release/2.22/master has been updated
via 561a9f11a974a447acb3dd03550a05df701a900e (commit)
from 19742d3d5f8fb0cdc95b20c32fbee503d1048286 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=561a9f11a974a447acb3dd03550a05df701a900e
commit 561a9f11a974a447acb3dd03550a05df701a900e
Author: Andreas Schwab <schwab@suse.de>
Date: Mon Aug 10 14:12:47 2015 +0200
Readd O_LARGEFILE flag for openat64 (bug 18781)
(cherry picked from commit eb32b0d40308166c4d8f6330cc2958cb1e545075)
diff --git a/ChangeLog b/ChangeLog
index e574072..ef1c608 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2015-08-10 Andreas Schwab <schwab@suse.de>
+
+ [BZ #18781]
+ * sysdeps/unix/sysv/linux/openat.c (__OPENAT) [MORE_OFLAGS]: Add
+ MORE_OFLAGS to oflag.
+ * io/test-lfs.c (do_test): Test openat64.
+
2015-08-08 John David Anglin <danglin@gcc.gnu.org>
[BZ #18787]
diff --git a/NEWS b/NEWS
index 258a4b0..e8ca542 100644
--- a/NEWS
+++ b/NEWS
@@ -9,7 +9,7 @@ Version 2.22.1
* The following bugs are resolved with this release:
- 18787.
+ 18781, 18787.
Version 2.22
diff --git a/io/test-lfs.c b/io/test-lfs.c
index 539c2a2..b6ebae4 100644
--- a/io/test-lfs.c
+++ b/io/test-lfs.c
@@ -144,7 +144,7 @@ test_ftello (void)
int
do_test (int argc, char *argv[])
{
- int ret;
+ int ret, fd2;
struct stat64 statbuf;
ret = lseek64 (fd, TWO_GB+100, SEEK_SET);
@@ -195,6 +195,25 @@ do_test (int argc, char *argv[])
error (EXIT_FAILURE, 0, "stat reported size %lld instead of %lld.",
(long long int) statbuf.st_size, (TWO_GB + 100 + 5));
+ fd2 = openat64 (AT_FDCWD, name, O_RDWR);
+ if (fd2 == -1)
+ {
+ if (errno == ENOSYS)
+ {
+ /* Silently ignore this test. */
+ error (0, 0, "openat64 is not supported");
+ }
+ else
+ error (EXIT_FAILURE, errno, "openat64 failed to open big file");
+ }
+ else
+ {
+ ret = close (fd2);
+
+ if (ret == -1)
+ error (EXIT_FAILURE, errno, "error closing file");
+ }
+
test_ftello ();
return 0;
diff --git a/sysdeps/unix/sysv/linux/openat.c b/sysdeps/unix/sysv/linux/openat.c
index 6777123..ad8e31d 100644
--- a/sysdeps/unix/sysv/linux/openat.c
+++ b/sysdeps/unix/sysv/linux/openat.c
@@ -68,6 +68,11 @@ __OPENAT (int fd, const char *file, int oflag, ...)
va_end (arg);
}
+ /* We have to add the O_LARGEFILE flag for openat64. */
+#ifdef MORE_OFLAGS
+ oflag |= MORE_OFLAGS;
+#endif
+
return SYSCALL_CANCEL (openat, fd, file, oflag, mode);
}
libc_hidden_def (__OPENAT)
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 7 +++++++
NEWS | 2 +-
io/test-lfs.c | 21 ++++++++++++++++++++-
sysdeps/unix/sysv/linux/openat.c | 5 +++++
4 files changed, 33 insertions(+), 2 deletions(-)
hooks/post-receive
--
GNU C Library master sources