File: alpha_atimensec.diff

package info (click to toggle)
qtbase-opensource-src 5.11.3%2Bdfsg1-1%2Bdeb10u5
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 313,804 kB
  • sloc: cpp: 1,831,962; ansic: 318,856; xml: 113,585; python: 9,691; java: 7,209; asm: 4,023; perl: 2,151; sh: 1,790; yacc: 1,733; lex: 1,197; javascript: 469; makefile: 301; objc: 70
file content (30 lines) | stat: -rw-r--r-- 1,188 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
Description: fix ambiguous definition of atime/mtime/ctime on alpha
 One of the implementations is enabled when the stat struct has
 ::st_atim member, another — when it has ::st_atimensec member.
 .
 On alpha, the stat struct has both members, defined as union here:
 https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/alpha/bits/stat.h#l48
 .
 and then used here:
 https://sourceware.org/git/?p=glibc.git;a=blob;f=sysdeps/unix/sysv/linux/alpha/bits/stat.h#l92
 .
 This patch forcefully disables the second implementation on alpha.
Author: Michael Cree <mcree@orcon.net.nz>
Forwarded: https://codereview.qt-project.org/245230
Last-Update: 2018-11-11

---
 src/corelib/io/qfilesystemengine_unix.cpp |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/src/corelib/io/qfilesystemengine_unix.cpp
+++ b/src/corelib/io/qfilesystemengine_unix.cpp
@@ -287,7 +287,7 @@ mtime(const T &statBuffer, int)
 { return timespecToMSecs(statBuffer.st_mtimespec); }
 #endif
 
-#ifndef st_mtimensec
+#if !defined(st_mtimensec) && !defined(__alpha__)
 // Xtimensec
 template <typename T>
 Q_DECL_UNUSED static typename std::enable_if<(&T::st_atimensec, true), qint64>::type