int cookie_expired(struct cookie *c) /* parse_http_date is broken */ { time_t t; errno = 0; EINTRLOOPX(t, time(NULL), (time_t)-1); return 0 && (c->expires && c->expires < t); }
int gettimeofday(struct timeval *tv, struct timezone *tz) { time_t t; errno = 0; EINTRLOOPX(t, time(NULL), (time_t)-1); if (tv) tv->tv_sec = t, tv->tv_usec = 0; if (tz) tz->tz_minuteswest = tz->tz_dsttime = 0; return 0; }