函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\parser.c Create Date:2022-07-27 07:16:20
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:match_number: scan a number in the given base from a substring_t*@s: substring to be scanned*@result: resulting integer on success*@base: base to use when converting string* Description: Given a &substring_t and a base, attempts to parse the substring

函数原型:static int match_number(substring_t *s, int *result, int base)

返回类型:int

参数:

类型参数名称
substring_t *s
int *result
intbase
133  buf等于match_strdup(s)
134  如果非buf则返回:负ENOMEM
137  ret等于0
138  val等于转换字符串为整形
139  如果endp恒等于bufret等于负EINVAL
141  否则如果val小于INT_MINval大于INT_MAXret等于负ERANGE
143  否则result等于val
145  kfree(buf)
146  返回:ret
调用者
名称描述
match_intmatch_int: - scan a decimal representation of an integer from a substring_t*@s: substring_t to be scanned*@result: resulting integer on success* Description: Attempts to parse the &substring_t @s as a decimal integer. On
match_octalmatch_octal: - scan an octal representation of an integer from a substring_t*@s: substring_t to be scanned*@result: resulting integer on success* Description: Attempts to parse the &substring_t @s as an octal integer
match_hexmatch_hex: - scan a hex representation of an integer from a substring_t*@s: substring_t to be scanned*@result: resulting integer on success* Description: Attempts to parse the &substring_t @s as a hexadecimal integer