Handle exception when calculate last modification time.