Merging upstream version 2.0.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
888be815c6
commit
e4376063b0
521 changed files with 21541 additions and 21644 deletions
|
@ -16,9 +16,9 @@
|
|||
|
||||
/**
|
||||
* match_one: - Determines if a string matches a simple pattern
|
||||
* @s: the string to examine for presence of the pattern
|
||||
* @p: the string containing the pattern
|
||||
* @args: array of %MAX_OPT_ARGS &substring_t elements. Used to return match
|
||||
* @s: the string to examine for presence of the pattern
|
||||
* @p: the string containing the pattern
|
||||
* @args: array of %MAX_OPT_ARGS &substring_t elements. Used to return match
|
||||
* locations.
|
||||
*
|
||||
* Description: Determines if the pattern @p is present in string @s. Can only
|
||||
|
@ -94,12 +94,12 @@ static int match_one(char *s, const char *p, substring_t args[])
|
|||
|
||||
/**
|
||||
* match_token: - Find a token (and optional args) in a string
|
||||
* @s: the string to examine for token/argument pairs
|
||||
* @table: match_table_t describing the set of allowed option tokens and the
|
||||
* arguments that may be associated with them. Must be terminated with a
|
||||
* &struct match_token whose pattern is set to the NULL pointer.
|
||||
* @args: array of %MAX_OPT_ARGS &substring_t elements. Used to return match
|
||||
* locations.
|
||||
* @s: the string to examine for token/argument pairs
|
||||
* @table: match_table_t describing the set of allowed option tokens and the
|
||||
* arguments that may be associated with them. Must be terminated with a
|
||||
* &struct match_token whose pattern is set to the NULL pointer.
|
||||
* @args: array of %MAX_OPT_ARGS &substring_t elements. Used to return match
|
||||
* locations.
|
||||
*
|
||||
* Description: Detects which if any of a set of token strings has been passed
|
||||
* to it. Tokens can include up to MAX_OPT_ARGS instances of basic c-style
|
||||
|
@ -118,9 +118,9 @@ int match_token(char *s, const match_table_t table, substring_t args[])
|
|||
|
||||
/**
|
||||
* 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
|
||||
* @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
|
||||
* as a number in that base. On success, sets @result to the integer represented
|
||||
|
@ -154,8 +154,8 @@ static int match_number(substring_t *s, int *result, int base)
|
|||
|
||||
/**
|
||||
* match_int: - scan a decimal representation of an integer from a substring_t
|
||||
* @s: substring_t to be scanned
|
||||
* @result: resulting integer on success
|
||||
* @s: substring_t to be scanned
|
||||
* @result: resulting integer on success
|
||||
*
|
||||
* Description: Attempts to parse the &substring_t @s as a decimal integer. On
|
||||
* success, sets @result to the integer represented by the string and returns 0.
|
||||
|
@ -168,8 +168,8 @@ int match_int(substring_t *s, int *result)
|
|||
|
||||
/**
|
||||
* match_octal: - scan an octal representation of an integer from a substring_t
|
||||
* @s: substring_t to be scanned
|
||||
* @result: resulting integer on success
|
||||
* @s: substring_t to be scanned
|
||||
* @result: resulting integer on success
|
||||
*
|
||||
* Description: Attempts to parse the &substring_t @s as an octal integer. On
|
||||
* success, sets @result to the integer represented by the string and returns
|
||||
|
@ -182,8 +182,8 @@ int match_octal(substring_t *s, int *result)
|
|||
|
||||
/**
|
||||
* match_hex: - scan a hex representation of an integer from a substring_t
|
||||
* @s: substring_t to be scanned
|
||||
* @result: resulting integer on success
|
||||
* @s: substring_t to be scanned
|
||||
* @result: resulting integer on success
|
||||
*
|
||||
* Description: Attempts to parse the &substring_t @s as a hexadecimal integer.
|
||||
* On success, sets @result to the integer represented by the string and
|
||||
|
@ -196,8 +196,8 @@ int match_hex(substring_t *s, int *result)
|
|||
|
||||
/**
|
||||
* match_wildcard: - parse if a string matches given wildcard pattern
|
||||
* @pattern: wildcard pattern
|
||||
* @str: the string to be parsed
|
||||
* @pattern: wildcard pattern
|
||||
* @str: the string to be parsed
|
||||
*
|
||||
* Description: Parse the string @str to check if matches wildcard
|
||||
* pattern @pattern. The pattern may contain two type wildcardes:
|
||||
|
@ -246,9 +246,9 @@ bool match_wildcard(const char *pattern, const char *str)
|
|||
|
||||
/**
|
||||
* match_strlcpy: - Copy the characters from a substring_t to a sized buffer
|
||||
* @dest: where to copy to
|
||||
* @src: &substring_t to copy
|
||||
* @size: size of destination buffer
|
||||
* @dest: where to copy to
|
||||
* @src: &substring_t to copy
|
||||
* @size: size of destination buffer
|
||||
*
|
||||
* Description: Copy the characters in &substring_t @src to the
|
||||
* c-style string @dest. Copy no more than @size - 1 characters, plus
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue