Cast timestamp before using it for formatted string.

time_t doesn't necessarily have to be a long number. In fact, manpage
for types.h mentions it can be a double value.