When running this code, the time gets stuck on 31.3.2013 : 1:mm:ss.
The minutes and seconds do not matter. The thing is that I can not increment the time by 1 hour, trying to do so by 60 minutes or 3600 seconds also doesn't work.
Yeah I'm running on 32-bit Windows 7 using gcc with C::B.
Right now it keeps looping until it gets "stuck", where increasing the value does not actually change it. I suspect the function std::mktime(std::tm*) to contain flaws.
Alright I figured it out, had to do with DST. Now I just inc/dec the time value directly by 3600 (seconds in an hour), works fine. This only stalls for an hour on dates like the 28th of October 2001 @ 2 AM, but that's okay, it steps over on the second iteration.