From 284e2b82b2c2dbd99cfc3138368ff8b6dd8fcd2a Mon Sep 17 00:00:00 2001 From: Marcel Moolenaar Date: Wed, 17 Jun 2015 03:12:08 +0000 Subject: [PATCH] Unbreak ``env LANG=ru_RU.KOI8-R ls -l''. Time strings are in the current locale. --- bin/ls/print.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/ls/print.c b/bin/ls/print.c index c96fe7cace41..de46169068b7 100644 --- a/bin/ls/print.c +++ b/bin/ls/print.c @@ -425,7 +425,7 @@ printtime(const char *field, time_t ftime) format = d_first ? "%e %b %Y" : "%b %e %Y"; strftime(longstring, sizeof(longstring), format, localtime(&ftime)); - snprintf(fmt, sizeof(fmt), "{:%s/%%s} ", field); + snprintf(fmt, sizeof(fmt), "{:%s/%%hs} ", field); xo_attr("value", "%ld", (long) ftime); xo_emit(fmt, longstring); }