fixed overflow problem on windows