From 47470044a1bf58f73c6a7978065bad38173c63e4 Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Sun, 13 Mar 2022 10:43:56 +0100 Subject: [PATCH] hardlink: set all locale elements, so that messages will get translated This setting and binding were lost a year ago, in commit 2180ecc81b. Signed-off-by: Benno Schulenberg --- misc-utils/hardlink.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/misc-utils/hardlink.c b/misc-utils/hardlink.c index 9320486227..d4bb48386e 100644 --- a/misc-utils/hardlink.c +++ b/misc-utils/hardlink.c @@ -1329,8 +1329,10 @@ int main(int argc, char *argv[]) sigaction(SIGINT, &sa, NULL); sigaction(SIGUSR1, &sa, NULL); - /* Pretty print numeric output */ - setlocale(LC_NUMERIC, ""); + /* Localize messages, number formatting, and anything else. */ + setlocale(LC_ALL, ""); + bindtextdomain(PACKAGE, LOCALEDIR); + textdomain(PACKAGE); if (atexit(to_be_called_atexit) != 0) err(EXIT_FAILURE, _("cannot register exit handler")); -- 2.47.2