diff options
Diffstat (limited to 'src/corelib/tools/qdatetime.cpp')
-rw-r--r-- | src/corelib/tools/qdatetime.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/corelib/tools/qdatetime.cpp b/src/corelib/tools/qdatetime.cpp index 7dd9060..6674717 100644 --- a/src/corelib/tools/qdatetime.cpp +++ b/src/corelib/tools/qdatetime.cpp @@ -1848,8 +1848,7 @@ QTime QTime::currentTime() #else time_t ltime; // no millisecond resolution ::time(<ime); - tm *t = 0; - localtime(<ime); + const tm *const t = localtime(<ime); ct.mds = MSECS_PER_HOUR * t->tm_hour + MSECS_PER_MIN * t->tm_min + 1000 * t->tm_sec; #endif return ct; |