timestamp.c: correctly convert negative UNIX timestamps