Use timegm()
instead of mktime()
Worth noting as pointed out by @chux – Reinstate Monica below is that time_t timegm(struct tm *timeptr)
is considered adding to the C23 standard (and thus by inclusion into the C++ standard).
Use timegm()
instead of mktime()
Worth noting as pointed out by @chux – Reinstate Monica below is that time_t timegm(struct tm *timeptr)
is considered adding to the C23 standard (and thus by inclusion into the C++ standard).