- tm = gmtime (&h->date_sent);
- snprintf (buf, sizeof (buf),
- "%d\t%s\t%s\t%d %s %d %02d:%02d:%02d GMT\t%s\t",
- h->article_num, h->env->subject, addr, tm->tm_mday,
- Months[tm->tm_mon], tm->tm_year + 1900, tm->tm_hour,
- tm->tm_min, tm->tm_sec, h->env->message_id);
- fputs (buf, f);
+
+ loc = setlocale(LC_TIME, "C");
+ strftime(buf, sizeof(buf), "%d %b %Y %H:%M:%S GMT", gmtime(&h->date_sent));
+ setlocale(LC_TIME, loc);
+
+ fprintf(f, "%d\t%s\t%s\t%s\t%s\t\n", h->article_num, h->env->subject,
+ addr, buf, h->env->message_id);