diff options
author | Pasi Petäjäjärvi <pasi.petajajarvi@digia.com> | 2013-01-08 14:01:40 (GMT) |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-01-10 13:34:02 (GMT) |
commit | 141482bb6eea76e361b0c6a64dd99551d43319f7 (patch) | |
tree | e80067a2dca76ea46e0fee9e4a25e8b9b8b9333f /src/corelib/tools | |
parent | 771b34fb0c62f8c1e982dbcf256bc90ddaba64b7 (diff) | |
download | Qt-141482bb6eea76e361b0c6a64dd99551d43319f7.zip Qt-141482bb6eea76e361b0c6a64dd99551d43319f7.tar.gz Qt-141482bb6eea76e361b0c6a64dd99551d43319f7.tar.bz2 |
Add struct keyword for timeval variable to remove ambiguity
VxWorks does not have gettimeofday function, so make sure we pick
correct definition for timeval. This is not needed in Qt5,
because there is already struct keyword used for timeval variable.
Change-Id: Iedb47e7c50610f64b0178527127fc003ee67ff4a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Diffstat (limited to 'src/corelib/tools')
-rw-r--r-- | src/corelib/tools/qelapsedtimer_unix.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/corelib/tools/qelapsedtimer_unix.cpp b/src/corelib/tools/qelapsedtimer_unix.cpp index f87c8ca..cad0081 100644 --- a/src/corelib/tools/qelapsedtimer_unix.cpp +++ b/src/corelib/tools/qelapsedtimer_unix.cpp @@ -127,7 +127,7 @@ static inline void do_gettime(qint64 *sec, qint64 *frac) } #endif // use gettimeofday - timeval tv; + struct timeval tv; ::gettimeofday(&tv, 0); *sec = tv.tv_sec; *frac = tv.tv_usec; |