Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\cmdline.c Create Date:2022-07-28 06:12:34
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:get_options - Parse a string into a list of integers*@str: String to be parsed*@nints: size of integer array*@ints: integer array* This function parses a string containing a comma-separated* list of integers, a hyphen-separated range of _positive_

Proto:char *get_options(const char *str, int nints, int *ints)

Type:char

Parameter:

TypeParameterName
const char *str
intnints
int *ints
89  i = 1
91  When i < nints cycle
92  res = get_option - Parse integer from an option string*@str: option string*@pint: (output) integer value parsed from @str* Read an int from an option string; if available accept a subsequent* comma as well
93  If res == 0 Then Break
95  If res == 3 Then
98  If range_nums < 0 Then Break
105  i += range_nums - 1
107  i++
108  If res == 1 Then Break
111  ints[0] = i - 1
112  Return str