From d93d69edff37f49b84c6eb1f9a52d09a55a9de2b Mon Sep 17 00:00:00 2001 From: Julian Smart Date: Thu, 11 Dec 2003 09:14:56 +0000 Subject: [PATCH] Applied patch [ 814047 ] fixes to enable compiling on gcc 3.3 git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@24746 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/common/longlong.cpp | 6 +++--- src/common/timercmn.cpp | 4 ++-- src/unix/threadpsx.cpp | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/common/longlong.cpp b/src/common/longlong.cpp index a76f895033..1baf36f4f4 100644 --- a/src/common/longlong.cpp +++ b/src/common/longlong.cpp @@ -1075,7 +1075,7 @@ wxLongLongWx::ToString() const wxLongLong ll = *this; bool neg; - if ( ll < 0 ) + if ( ll < 0L ) { ll.Negate(); neg = TRUE; @@ -1085,9 +1085,9 @@ wxLongLongWx::ToString() const neg = FALSE; } - while ( ll != 0 ) + while ( ll != 0L ) { - result.Prepend((wxChar)(_T('0') + (ll % 10).ToLong())); + result.Prepend((wxChar)(_T('0') + (ll % 10L).ToLong())); ll /= 10; } diff --git a/src/common/timercmn.cpp b/src/common/timercmn.cpp index b40122a1fe..0f0b478fdb 100644 --- a/src/common/timercmn.cpp +++ b/src/common/timercmn.cpp @@ -167,7 +167,7 @@ bool wxTimerBase::Start(int milliseconds, bool oneShot) void wxStopWatch::Start(long t) { - m_t0 = wxGetLocalTimeMillis() - t; + m_t0 = wxGetLocalTimeMillis() - (wxLongLong)t; m_pause = 0; m_pauseCount = 0; } @@ -329,7 +329,7 @@ wxLongLong wxGetLocalTimeMillis() if ( wxGetTimeOfDay(&tp, (struct timezone *)NULL) != -1 ) { val *= tp.tv_sec; - return (val + (tp.tv_usec / 1000)); + return (val + (wxLongLong)(tp.tv_usec / 1000)); } else { diff --git a/src/unix/threadpsx.cpp b/src/unix/threadpsx.cpp index b4b91685b9..bdb51c7212 100644 --- a/src/unix/threadpsx.cpp +++ b/src/unix/threadpsx.cpp @@ -374,7 +374,7 @@ wxCondError wxConditionInternal::WaitTimeout(unsigned long milliseconds) { wxLongLong curtime = wxGetLocalTimeMillis(); curtime += milliseconds; - wxLongLong temp = curtime / 1000; + wxLongLong temp = curtime / 1000L; int sec = temp.GetLo(); temp *= 1000; temp = curtime - temp;