Lines Matching refs:ret

90 	int ret=0, count=0;  in str2int()  local
93 ret = ret*10 + (*buf[0] - '0'); in str2int()
100 return ret; in str2int()
109 int c, ret; in unbound_strptime() local
133 ret = match_string(&s, full_weekdays); in unbound_strptime()
134 if (ret < 0) in unbound_strptime()
135 ret = match_string(&s, abb_weekdays); in unbound_strptime()
136 if (ret < 0) { in unbound_strptime()
139 tm->tm_wday = ret; in unbound_strptime()
144 ret = match_string(&s, full_months); in unbound_strptime()
145 if (ret < 0) in unbound_strptime()
146 ret = match_string(&s, abb_months); in unbound_strptime()
147 if (ret < 0) { in unbound_strptime()
150 tm->tm_mon = ret; in unbound_strptime()
158 ret = str2int(&s, 2); in unbound_strptime()
159 if (ret < 0 || ret > 99) { /* must be in [00,99] */ in unbound_strptime()
164 tm->tm_year = ret*100 + (tm->tm_year%100); in unbound_strptime()
167 tm->tm_year = ret*100 - TM_YEAR_BASE; in unbound_strptime()
173 ret = str2int(&s, 2); in unbound_strptime()
174 if (ret < 1 || ret > 31) { /* must be in [01,31] */ in unbound_strptime()
177 tm->tm_mday = ret; in unbound_strptime()
185 ret = str2int(&s, 2); in unbound_strptime()
186 if (ret < 0 || ret > 23) { /* must be in [00,23] */ in unbound_strptime()
189 tm->tm_hour = ret; in unbound_strptime()
192 ret = str2int(&s, 2); in unbound_strptime()
193 if (ret < 1 || ret > 12) { /* must be in [01,12] */ in unbound_strptime()
196 if (ret == 12) /* actually [0,11] */ in unbound_strptime()
197 ret = 0; in unbound_strptime()
198 tm->tm_hour = ret; in unbound_strptime()
201 ret = str2int(&s, 2); in unbound_strptime()
202 if (ret < 1 || ret > 366) { /* must be in [001,366] */ in unbound_strptime()
205 tm->tm_yday = ret; in unbound_strptime()
208 ret = str2int(&s, 2); in unbound_strptime()
209 if (ret < 1 || ret > 12) { /* must be in [01,12] */ in unbound_strptime()
213 tm->tm_mon = (ret-1); in unbound_strptime()
216 ret = str2int(&s, 2); in unbound_strptime()
217 if (ret < 0 || ret > 59) { /* must be in [00,59] */ in unbound_strptime()
220 tm->tm_min = ret; in unbound_strptime()
228 ret = match_string(&s, ampm); in unbound_strptime()
229 if (ret < 0) { in unbound_strptime()
236 if (ret == 1) /* pm */ in unbound_strptime()
250 ret = str2int(&s, 2); in unbound_strptime()
253 if (ret < 0 || ret > 60) { /* must be in [00,60] */ in unbound_strptime()
256 tm->tm_sec = ret; in unbound_strptime()
264 ret = str2int(&s, 2); in unbound_strptime()
265 if (ret < 0 || ret > 53) { /* must be in [00,53] */ in unbound_strptime()
273 ret = str2int(&s, 1); in unbound_strptime()
274 if (ret < 0 || ret > 6) { /* must be in [0,6] */ in unbound_strptime()
277 tm->tm_wday = ret; in unbound_strptime()
280 ret = str2int(&s, 2); in unbound_strptime()
281 if (ret < 0 || ret > 53) { /* must be in [00,53] */ in unbound_strptime()
299 ret = str2int(&s, 2); in unbound_strptime()
300 if (ret < 0 || ret > 99) { /* must be in [00,99] */ in unbound_strptime()
304 tm->tm_year = ((tm->tm_year/100) * 100) + ret; in unbound_strptime()
313 if (ret < 69) /* 2000 */ in unbound_strptime()
314 ret += 100; in unbound_strptime()
315 tm->tm_year = ret; in unbound_strptime()
319 ret = str2int(&s, 4); in unbound_strptime()
320 if (ret < 0 || ret > 9999) { in unbound_strptime()
323 tm->tm_year = ret - TM_YEAR_BASE; in unbound_strptime()