git: date(1): Fix the default format.
Sascha Wildner
swildner at crater.dragonflybsd.org
Fri Oct 4 00:42:45 PDT 2013
commit 25c9e89df0d2e2dd5218f416fecd26dcdb0a5bb8
Author: Sascha Wildner <saw at online.de>
Date: Fri Oct 4 08:44:06 2013 +0200
date(1): Fix the default format.
The correct format string for national representation of date(1)'s default
output is "date_fmt" (see /usr/src/share/timedef/*), which is not returned
by any standard nl_langinfo() constant. Previously, we defined our own
_DATE_FMT constant and handled it as an extension of nl_langinfo().
The locale upgrade removed nl_langinfo()'s _DATE_FMT handling and at the
same time brought in a change that causes "date_fmt" to be returned when
using "%+" as strftime()'s format.
That means, a nl_langinfo() call in date(1) is no longer needed, even
wrong (there is no constant returning the representation date(1) needs),
since strftime() can handle it all by itself directly and we can just use
"%+", like FreeBSD does, too.
Summary of changes:
bin/date/date.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/25c9e89df0d2e2dd5218f416fecd26dcdb0a5bb8
--
DragonFly BSD source repository
More information about the Commits
mailing list