Quote:
|
Originally Posted by deltacoder1020
nice catch, Ken. the code this is based off of is an example that I posted on the forums here: http://www.chiefdelphi.com/forums/sh...d.php?p=233912
the problem is that for any time period larger than about 3 seconds, 10000*a is greater than the max limit for a plain "int", and thus it's either wrapping around or just mucking stuff up.
...
|
The easy fix is to use ((unsigned int)(a)) instead of int. you will never need negative time, so why specify a signed number?
Cheers!