Lines Matching defs:tm
103 /** Converts the character string s to values which are stored in tm
107 unbound_strptime(const char *s, const char *format, struct tm *tm)
139 tm->tm_wday = ret;
150 tm->tm_mon = ret;
153 if (!(s = unbound_strptime(s, "%x %X", tm))) {
164 tm->tm_year = ret*100 + (tm->tm_year%100);
167 tm->tm_year = ret*100 - TM_YEAR_BASE;
177 tm->tm_mday = ret;
180 if (!(s = unbound_strptime(s, "%m/%d/%y", tm))) {
189 tm->tm_hour = ret;
198 tm->tm_hour = ret;
205 tm->tm_yday = ret;
213 tm->tm_mon = (ret-1);
220 tm->tm_min = ret;
232 if (tm->tm_hour < 0 || tm->tm_hour > 11) { /* %I */
237 tm->tm_hour += 12;
240 if (!(s = unbound_strptime(s, "%I:%M:%S %p", tm))) {
245 if (!(s = unbound_strptime(s, "%H:%M", tm))) {
256 tm->tm_sec = ret;
259 if (!(s = unbound_strptime(s, "%H:%M:%S", tm))) {
277 tm->tm_wday = ret;
289 if (!(s = unbound_strptime(s, "%m/%d/%y", tm))) {
294 if (!(s = unbound_strptime(s, "%H:%M:%S", tm))) {
304 tm->tm_year = ((tm->tm_year/100) * 100) + ret;
315 tm->tm_year = ret;
323 tm->tm_year = ret - TM_YEAR_BASE;