]> git.mxchange.org Git - flightgear.git/commit
There was an integer overflow in the way elapsed_time_ms. Because the
authorcurt <curt>
Sat, 20 Apr 2002 14:52:43 +0000 (14:52 +0000)
committercurt <curt>
Sat, 20 Apr 2002 14:52:43 +0000 (14:52 +0000)
commit586d767ab6a2ff9900cf043bad5696c983f14fd8
treecb815ec9fc1faccafc458759457596df47dc449f
parent89324e0cfe0970eafe982843c830770ef0591a51
There was an integer overflow in the way elapsed_time_ms.  Because the
SGTimeStamp "-" operator returns it's result in usec's, there is an upper bound of 37.8 minutes on the maximum difference this operator can reliably report
before the math overflows.  I change the global "int elapsed_time_ms" variable
to a "double sim_time_ms" and restructured how the value is calculated.
----
The practical result of the overflow bug is that a large negative dt was
passed to the event manager and the end effect was that no events would
be run until their counters caught up ... in another 37.8 minutes or so.
src/Main/fg_props.cxx
src/Main/globals.cxx
src/Main/globals.hxx
src/Main/logger.cxx
src/Main/logger.hxx
src/Main/main.cxx