    return f.good();
  }
  
  }
  
  class ExitHandler {
  public:
    ExitHandler() {
      std::signal(SIGINT, (sighandler_t)set_do_exit);
 
</s> remove   struct tm sys_time;
  gmtime_r(&rawtime, &sys_time);

  return sys_time;
}

bool time_valid(struct tm sys_time){
  int year = 1900 + sys_time.tm_year;
  int month = 1 + sys_time.tm_mon;
  return (year > 2020) || (year == 2020 && month >= 10);
}
 </s> add  </s> remove struct tm get_time(){
  time_t rawtime;
  time(&rawtime);
 </s> add  </s> remove     if (!time_valid(sys_time) && time_valid(rtc_time)) {
 </s> add     if (!util::time_valid(sys_time) && util::time_valid(rtc_time)) {
inline std::string hexdump(const std::string& in) {
    std::stringstream ss;
    ss << std::hex << std::setfill('0');
    for (size_t i = 0; i < in.size(); i++) {
        ss << std::setw(2) << static_cast<unsigned int>(static_cast<unsigned char>(in[i]));
    }
    return ss.str();
}

    return f.good();
  }
  
inline std::string hexdump(const std::string& in) {
    std::stringstream ss;
    ss << std::hex << std::setfill('0');
    for (size_t i = 0; i < in.size(); i++) {
        ss << std::setw(2) << static_cast<unsigned int>(static_cast<unsigned char>(in[i]));
    }
    return ss.str();
}

  }
  
  class ExitHandler {
  public:
    ExitHandler() {
      std::signal(SIGINT, (sighandler_t)set_do_exit);
keep keep add keep keep keep keep keep keep
 Store almanac on ublox poweroff (#20967)

* Store almanac on ublox poweroff

* send current UTC time

* move message building to ublox_msg.h 
selfdrive/common/util.h