check result of mktime() to trap invalid timestamps