#include "date.h" #include <stdlib.h> extern struct tz_tab tzs; extern char *tzname[2]; extern time_t timezone; extern int daylight; int main (int argc, char *argv[]) { time_t tt; char *s; int t; t = argc - 1; do { tt = time(NULL); s = get_tsm_date(tt, t); if (s == NULL) { fprintf (stderr, "\nError while formatting TSM date\n"); return 1; } fprintf (stdout, "\nTimestamp: %d", (int)tt); fprintf (stdout, "\nTSM date is: [%s]", s); fprintf (stdout, "\n"); } while (t); return 0; }