rees@apollo.uucp (Jim Rees) (06/19/87)
This may seem like a nit, but it's been bugging me so I fixed it. The default date format in the history file is hopelessly Americanized and ambiguous, using '/' as a separator with no indication as to which field is the month or the year. The date parser can handle this, but it's an insult to our European (in fact, all our non-American) friends. They are used to a more rational format. We're all familiar with the classic byte-sex problem; is the first one most or least significant? This problem pales in comparison with the date-sex problem. In this case, the least significant field (the day) is in the middle! Reminds me of floating point on the Vax. Anyway, I fixed my code to use arpadate(). The news code already contains a date printing routine; why not use it? The result is shorter, easier to read, and eliminates an ugly system dependency (#ifdefed on USG). Rather than a context diff, here are the first few lines of insert() (in inews.c). /* Clean up Newsgroups: line */ if (!is_ctl && mode != CREATENG) is_invalid = ngfcheck(mode == PROC); (void) time(&now); if (header.expdate[0]) addhist(" "); addhist(arpadate(&now)); addhist("\t"); log("%s %s ng %s subj '%s' from %s", spool_news != DONT_SPOOL ? "queued" : (mode==PROC ? "received" : "posted"), header.ident, header.nbuf, header.title, header.from); /* Write article to temp file. */ tfp = xfopen(mktemp(ARTICLE), "w");