From 88e4ad1d3673996f718ae70099105e67084cdbad Mon Sep 17 00:00:00 2001 From: Jim Meyering Date: Sat, 18 Aug 2001 10:54:56 +0000 Subject: (show_date) [--rfc-822]: Don't space-pad the day of the month. Set only LC_TYPE to the "C" locale. Setting LC_ALL is overkill, and would have unwanted side effects if there is an error message. --- src/date.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/date.c') diff --git a/src/date.c b/src/date.c index 64aeed4a2..3e75899d1 100644 --- a/src/date.c +++ b/src/date.c @@ -76,7 +76,7 @@ char *program_name; /* If nonzero, display an ISO 8601 format date/time string */ static int iso_8601_format = 0; -/* If non-zero, display time in RFC-822 format for mail or news. */ +/* If non-zero, display time in RFC-(2)822 format for mail or news. */ static int rfc_format = 0; static struct option const long_options[] = @@ -466,7 +466,7 @@ show_date (const char *format, time_t when) RFC time format outside the continental United States and GMT. */ if (rfc_format) - format = "%a, %_d %b %Y %H:%M:%S %z"; + format = "%a, %d %b %Y %H:%M:%S %z"; else if (iso_8601_format) format = iso_format_string[iso_8601_format - 1]; else @@ -489,7 +489,7 @@ show_date (const char *format, time_t when) } if (rfc_format) - setlocale (LC_ALL, "C"); + setlocale (LC_TIME, "C"); do { -- cgit v1.2.3-54-g00ecf