summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWade Berrier <wade_berrier@appsig.com>2011-06-08 21:46:55 (GMT)
committer Denys Vlasenko <vda.linux@googlemail.com>2011-06-10 04:01:30 (GMT)
commit000ae5cefe204aec44e7997440c4ea7eca5d4893 (patch)
tree42d91503e5665682d1b3e06e74af77fc9ebcfd36
parent6295d273add9e72f7074d44eeee7a2c281bac975 (diff)
downloadbusybox-000ae5cefe204aec44e7997440c4ea7eca5d4893.tar.gz
busybox-000ae5cefe204aec44e7997440c4ea7eca5d4893.tar.bz2
pkill/pgrep: support extended regular expressions
Done by enabling the REG_EXTENDED and REG_NOSUB regex flags, which also increases compatibility with the procps versions. Signed-off-by: Wade Berrier <wade_berrier@appsig.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r--procps/pgrep.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/procps/pgrep.c b/procps/pgrep.c
index 156b4ad..dc7ffff 100644
--- a/procps/pgrep.c
+++ b/procps/pgrep.c
@@ -128,7 +128,7 @@ int pgrep_main(int argc UNUSED_PARAM, char **argv)
bb_show_usage();
if (argv[0])
- xregcomp(&re_buffer, argv[0], 0);
+ xregcomp(&re_buffer, argv[0], REG_EXTENDED | REG_NOSUB);
matched_pid = 0;
cmd_last = NULL;