• Home
  • Raw
  • Download

Lines Matching refs:tm

97 static  unsigned char *_strptime(const unsigned char *, const char *, struct tm *,
102 strptime(const char *buf, const char *fmt, struct tm *tm) in strptime() argument
107 return (char*)(_strptime((const unsigned char*)buf, fmt, tm, &cr)); in strptime()
111 _strptime(const unsigned char *buf, const char *fmt, struct tm *tm, struct century_relyear *cr) in _strptime() argument
163 if (!(bp = _strptime(bp, _ctloc(d_t_fmt), tm, cr))) in _strptime()
169 if (!(bp = _strptime(bp, "%m/%d/%y", tm, cr))) in _strptime()
175 if (!(bp = _strptime(bp, "%H:%M", tm, cr))) in _strptime()
181 if (!(bp = _strptime(bp, "%I:%M:%S %p", tm, cr))) in _strptime()
187 if (!(bp = _strptime(bp, "%H:%M:%S", tm, cr))) in _strptime()
193 if (!(bp = _strptime(bp, _ctloc(t_fmt), tm, cr))) in _strptime()
199 if (!(bp = _strptime(bp, _ctloc(d_fmt), tm, cr))) in _strptime()
225 tm->tm_wday = i; in _strptime()
249 tm->tm_mon = i; in _strptime()
264 if (!(_conv_num(&bp, &tm->tm_mday, 1, 31))) in _strptime()
273 if (!(_conv_num(&bp, &tm->tm_hour, 0, 23))) in _strptime()
282 if (!(_conv_num(&bp, &tm->tm_hour, 1, 12))) in _strptime()
288 if (!(_conv_num(&bp, &tm->tm_yday, 1, 366))) in _strptime()
290 tm->tm_yday--; in _strptime()
295 if (!(_conv_num(&bp, &tm->tm_min, 0, 59))) in _strptime()
301 if (!(_conv_num(&bp, &tm->tm_mon, 1, 12))) in _strptime()
303 tm->tm_mon--; in _strptime()
311 if (tm->tm_hour > 12) /* i.e., 13:00 AM ?! */ in _strptime()
313 else if (tm->tm_hour == 12) in _strptime()
314 tm->tm_hour = 0; in _strptime()
322 if (tm->tm_hour > 12) /* i.e., 13:00 PM ?! */ in _strptime()
324 else if (tm->tm_hour < 12) in _strptime()
325 tm->tm_hour += 12; in _strptime()
336 if (!(_conv_num(&bp, &tm->tm_sec, 0, 61))) in _strptime()
355 if (!(_conv_num(&bp, &tm->tm_wday, 0, 6))) in _strptime()
365 tm->tm_year = i - TM_YEAR_BASE; in _strptime()
399 tm->tm_year = cr->relyear + 2000 - TM_YEAR_BASE; in _strptime()
401 tm->tm_year = cr->relyear + 1900 - TM_YEAR_BASE; in _strptime()
403 tm->tm_year = cr->relyear + cr->century - TM_YEAR_BASE; in _strptime()