]> granicus.if.org Git - strace/commitdiff
2005-02-02 Roland McGrath <roland@redhat.com>
authorRoland McGrath <roland@redhat.com>
Wed, 2 Feb 2005 22:11:32 +0000 (22:11 +0000)
committerRoland McGrath <roland@redhat.com>
Wed, 2 Feb 2005 22:11:32 +0000 (22:11 +0000)
* file.c (openmodes) [O_LARGEFILE] [O_LARGEFILE == 0]: Redefine to
known values for Linux.

file.c

diff --git a/file.c b/file.c
index 3960afbc48b59995d7b01613289151652f88b5ca..630f973e6080b3d6a6865c643054c37ba7029b8a 100644 (file)
--- a/file.c
+++ b/file.c
@@ -237,6 +237,14 @@ const struct xlat openmodes[] = {
        { O_DIRECT,     "O_DIRECT"      },
 #endif
 #ifdef O_LARGEFILE
+# if O_LARGEFILE == 0          /* biarch platforms in 64-bit mode */
+#  undef O_LARGEFILE
+#  ifdef SPARC64
+#   define O_LARGEFILE 0x40000
+#  elif defined X86_64 || defined S390X
+#   define O_LARGEFILE 0100000
+#  endif
+# endif
        { O_LARGEFILE,  "O_LARGEFILE"   },
 #endif
 #ifdef O_DIRECTORY