Thread (22 messages) flat view 22 messages, 6 authors, 2017-05-18

Re: [PATCH v1 2/5] Teach git to optionally utilize a file system monitor to speed up detecting new or changed files.

From: Jeff King <hidden>
Date: 2017-05-16 02:51:27

On Mon, May 15, 2017 at 09:55:12PM -0400, Ben Peart wrote:
quoted
quoted
quoted
+	istate->last_update = (time_t)ntohll(*(uint64_t *)index);
[...]
quoted
(I note also that time_t is not necessarily 64-bits in the first place,
but David said something about this not really being a time_t).
The in memory representation is a time_t as that is the return value of
time(NULL) but it is converted to/from a 64 bit value when written/read to
the index extension so that the index format is the same no matter the
native size of time_t.
OK. I guess your cast here will truncate on 32-bit systems, but
presumably not until 2038, so we can perhaps ignore it for now (and
anyway, time(NULL) will be broken on such a system at that point).

-Peff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help