From: Jaromir Capik Date: Wed, 16 Jul 2014 12:29:42 +0000 (+0200) Subject: sysctl: support expansion of csh style braces with -p X-Git-Tag: v3.3.10~54 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f8128568d671d2c07b7d2faf0bc399fb9b7bd69e;p=procps-ng sysctl: support expansion of csh style braces with -p This commit adds the GLOB_BRACE flag in the glob flags. That allows to expand the csh style braces {a,b} and define multiple independent patterns for config file locations. --- diff --git a/sysctl.c b/sysctl.c index fc224e5d..bc83b50f 100644 --- a/sysctl.c +++ b/sysctl.c @@ -502,7 +502,7 @@ static int Preload(const char *restrict const filename) int globerr; int j; - globerr = glob(filename, GLOB_NOCHECK | GLOB_TILDE, NULL, &globbuf); + globerr = glob(filename, GLOB_NOCHECK | GLOB_TILDE | GLOB_BRACE, NULL, &globbuf); if (globerr != 0 && globerr != GLOB_NOMATCH) xerr(EXIT_FAILURE, _("glob failed"));