Lines Matching refs:date
43 * date - with format capabilities and international flair
98 gettext("date: invalid argument -- %s\n"),
126 perror(gettext("date: Failed to adjust date"));
160 setdate(struct tm *current_date, char *date)
174 /* Parse date string */
175 if ((secptr = strchr(date, '.')) != NULL && strlen(&secptr[1]) == 2 &&
180 len = strlen(date);
183 if (!isdigit(date[i])) {
185 gettext("date: bad conversion\n"));
189 switch (strlen(date)) {
191 yy = atoi(&date[8]);
192 date[8] = '\0';
200 if (atoi(&date[8]) <= 68) {
201 yy = 1900 + (atoi(&date[8]) + 100);
203 yy = 1900 + atoi(&date[8]);
205 date[8] = '\0';
217 (void) fprintf(stderr, gettext("date: bad conversion\n"));
221 min = atoi(&date[minidx]);
222 date[minidx] = '\0';
223 hh = atoi(&date[minidx-2]);
224 date[minidx-2] = '\0';
231 dd = atoi(&date[2]);
232 date[2] = '\0';
233 mm = atoi(&date[0]);
239 /* Validate date elements */
248 (void) fprintf(stderr, gettext("date: bad conversion\n"));
252 /* Build date and time number */
291 perror("date");