lkml.org 
[lkml]   [2018]   [May]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [RFC][PATCH 07/10] tracing: Have zero size length in filter logic be full string
On Fri, May 11, 2018 at 9:49 PM, Steven Rostedt <rostedt@goodmis.org> wrote:
[]
>
> static int regex_match_front(char *str, struct regex *r, int len)
> {
> - if (len < r->len)
> + if (len && len < r->len)
> return 0;
>
> - if (strncmp(str, r->pattern, r->len) == 0)
> - return 1;
> - return 0;
> + return strncmp(str, r->pattern, len) == 0;

strncmp(..., r->len) still?

> }

Regards,
Yann.

\
 
 \ /
  Last update: 2018-05-12 20:33    [W:0.067 / U:0.348 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site