Rudimentary support for HTTP Date headers
Since I'm going on a personal crusade to kill off gmt_unix_time, I
should provide an alternative. That alternative can be the Date
header from HTTP -- unlike gmt_unix_time, the Date header is required
by the RFC to actually be an accurate clock-like clock, and nobody is
trying to get rid of it.
This code is pretty hack-ish and does some nonportable stuff, like
using memmem() and timegm(). It's not super-tolerant of
non-standards-compliant HTTP servers. I hope I didn't make any
pointer mistakes.
4 files changed