I'm trying to compile nginx on for a raspberry pi
src/core/ngx_times.c
time_t sec;
ngx_uint_t msec;
struct timeval tv;
ngx_gettimeofday(&tv);
sec = tv.tv_sec;
msec = tv.tv_usec / 1000;
ngx_current_msec = (ngx_msec_t) sec * 1000 + msec;
ngx_current_msec is defined as a ngx_msec_t which in turn is ngx_uint_t. In an rpi is not big enough to hold Unix epoc in millis. (sec * 1000)
nginx code does compile, but my tests fail: they have hardcoded values for the epoc.
Is this deliberate? I guess its cropping the high order bits? So millis comparisons might work but timestamps generated from this value might not?