Lines Matching refs:tm
11 * add additional nonstandard fields to struct tm... */
13 int tm_cmp(struct tm tm1, struct tm tm2)
26 char *tm_str(struct tm tm)
33 tm.tm_sec, tm.tm_min, tm.tm_hour,
34 tm.tm_mday, tm.tm_mon, tm.tm_year,
35 tm.tm_wday, tm.tm_yday, tm.tm_isdst);
39 #define TM(ss,mm,hh,md,mo,yr,wd,yd,dst) (struct tm){ \
50 struct tm *tm;
54 tm = gmtime(&t);
59 r = mktime(tm);
62 m, tm_str(*tm), strerror(errno));
65 m, (long long)t, (long long)r, tm_str(*tm));
68 static void tm2sec(struct tm *tm, int big, char *m)
70 struct tm *r;
75 t = mktime(tm);
78 m, tm_str(*tm), (long)t);
81 m, tm_str(*tm), strerror(EOVERFLOW), strerror(errno));
84 m, tm_str(*tm));
87 m, tm_str(*tm), strerror(errno));
89 if (!overflow && tm_cmp(*r, *tm))
91 m, tm_str(*tm), tm_str(*r));