Morgan243 / python-on-a-chip

Automatically exported from code.google.com/p/python-on-a-chip
Other
0 stars 0 forks source link

Fix sys.time overflow #254

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Report from Marcus Priesch via email on 2013/11/01::

Hello Dean,

today i did some testing ... and sys.time () overflow every 49 days caused me
some headaches ... ,)

with your implementation sys.time yould have thrown a type error in the
latter 49/2 days ;) - which nevertheless would have restarted the application
in my case ... also the scheduler would have stopped after an oferrun ...

this led me to the attached patch ...

sys.time () now only returns msecs until sys.maxint is reached, when
overflowing, sys.wait () now also handles this correctly ...

feel free to adapt ;)

regards,
marcus.

Original issue reported on code.google.com by dwhall...@gmail.com on 5 Nov 2013 at 4:10

Attachments:

GoogleCodeExporter commented 8 years ago
Resolved by r713d9237869c

Original comment by dwhall...@gmail.com on 5 Nov 2013 at 4:42

GoogleCodeExporter commented 8 years ago
I added an else clause to Marcus' path and that was not correct.  I need to 
revert to exactly match the patch.

Original comment by dwhall...@gmail.com on 6 Nov 2013 at 3:20

GoogleCodeExporter commented 8 years ago
This issue was closed by revision 5dc724e5104b.

Original comment by dwhall...@gmail.com on 6 Nov 2013 at 3:22