diff options
Diffstat (limited to 'procps/pgrep.c')
-rw-r--r-- | procps/pgrep.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/procps/pgrep.c b/procps/pgrep.c index f20789c81..336fa84ba 100644 --- a/procps/pgrep.c +++ b/procps/pgrep.c | |||
@@ -115,7 +115,7 @@ int pgrep_main(int argc ATTRIBUTE_UNUSED, char **argv) | |||
115 | cmd = proc->comm; | 115 | cmd = proc->comm; |
116 | /* NB: OPT_INVERT is always 0 or 1 */ | 116 | /* NB: OPT_INVERT is always 0 or 1 */ |
117 | if ((regexec(&re_buffer, cmd, 1, re_match, 0) == 0 /* match found */ | 117 | if ((regexec(&re_buffer, cmd, 1, re_match, 0) == 0 /* match found */ |
118 | && (!OPT_ANCHOR || (re_match[0].rm_so == 0 && re_match[0].rm_eo == strlen(cmd)))) ^ OPT_INVERT | 118 | && (!OPT_ANCHOR || (re_match[0].rm_so == 0 && re_match[0].rm_eo == (regoff_t)strlen(cmd)))) ^ OPT_INVERT |
119 | ) { | 119 | ) { |
120 | matched_pid = proc->pid; | 120 | matched_pid = proc->pid; |
121 | if (OPT_LAST) { | 121 | if (OPT_LAST) { |