函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\trace\trace_events_filter.c Create Date:2022-07-27 13:32:51
Last Modify:2022-05-22 20:19:57 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:lter_parse_regex - parse a basic regex*@buff: the raw regex*@len: length of the regex*@search: will point to the beginning of the string to compare*@not: tell whether the match will have to be inverted* This passes in a buffer containing a regex and this

函数原型:enum regex_type filter_parse_regex(char *buff, int len, char **search, int *not)

返回类型:enum regex_type

参数:

类型参数名称
char *buff
intlen
char **search
int *not
823  type等于MATCH_FULL
826  如果buff[0]恒等于'!'则
827  not等于1
828  buff自加
829  len自减
830  否则not等于0
833  search等于buff
835  如果是数字则返回:MATCH_INDEX
838 i小于len循环
839  如果buff[i]恒等于'*'则
840  如果非i
841  type等于MATCH_END_ONLY
842  否则如果i恒等于len减1则
843  如果type恒等于MATCH_END_ONLYtype等于MATCH_MIDDLE_ONLY
845  否则type等于MATCH_FRONT_ONLY
847  buff[i]等于0
848  退出
849  否则
850  返回:MATCH_GLOB
853  返回:MATCH_GLOB
856  如果buff[0]恒等于'*'则search等于buff加1
859  返回:type
调用者
名称描述
filter_build_regex