summaryrefslogtreecommitdiffstats
path: root/usr.bin/pkill
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2004-07-15 08:13:56 +0000
committertjr <tjr@FreeBSD.org>2004-07-15 08:13:56 +0000
commita2ba9d448dddaf9ca08b0de9a03349bb8c0dffe6 (patch)
tree1eb0617040fc944e32b7efd22035250f8d1f484e /usr.bin/pkill
parentbcc5104ce1c31b23fe0d246ee43347f0673fcb5c (diff)
downloadFreeBSD-src-a2ba9d448dddaf9ca08b0de9a03349bb8c0dffe6.zip
FreeBSD-src-a2ba9d448dddaf9ca08b0de9a03349bb8c0dffe6.tar.gz
Respect locale settings from the environment.
Diffstat (limited to 'usr.bin/pkill')
-rw-r--r--usr.bin/pkill/pkill.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/usr.bin/pkill/pkill.c b/usr.bin/pkill/pkill.c
index fa17d6e..3051f95 100644
--- a/usr.bin/pkill/pkill.c
+++ b/usr.bin/pkill/pkill.c
@@ -62,6 +62,7 @@ __FBSDID("$FreeBSD$");
#include <pwd.h>
#include <grp.h>
#include <errno.h>
+#include <locale.h>
#define STATUS_MATCH 0
#define STATUS_NOMATCH 1
@@ -132,6 +133,8 @@ main(int argc, char **argv)
regex_t reg;
regmatch_t regmatch;
+ setlocale(LC_ALL, "");
+
if (strcmp(getprogname(), "pgrep") == 0) {
action = grepact;
pgrep = 1;
OpenPOWER on IntegriCloud