mirror of
https://github.com/samba-team/samba.git
synced 2025-02-28 01:58:17 +03:00
s3-lib Remove unused str_ascii_charnum()
This commit is contained in:
parent
9d62ee2a81
commit
aad2c19da7
@ -961,7 +961,6 @@ void strnorm(char *s, int case_default);
|
|||||||
char *push_skip_string(char *buf);
|
char *push_skip_string(char *buf);
|
||||||
char *skip_string(const char *base, size_t len, char *buf);
|
char *skip_string(const char *base, size_t len, char *buf);
|
||||||
size_t str_charnum(const char *s);
|
size_t str_charnum(const char *s);
|
||||||
size_t str_ascii_charnum(const char *s);
|
|
||||||
bool trim_char(char *s,char cfront,char cback);
|
bool trim_char(char *s,char cfront,char cback);
|
||||||
bool strhasupper(const char *s);
|
bool strhasupper(const char *s);
|
||||||
bool strhaslower(const char *s);
|
bool strhaslower(const char *s);
|
||||||
|
@ -274,24 +274,6 @@ size_t str_charnum(const char *s)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
Count the number of characters in a string. Normally this will
|
|
||||||
be the same as the number of bytes in a string for single byte strings,
|
|
||||||
but will be different for multibyte.
|
|
||||||
**/
|
|
||||||
|
|
||||||
size_t str_ascii_charnum(const char *s)
|
|
||||||
{
|
|
||||||
size_t ret, converted_size;
|
|
||||||
char *tmpbuf2 = NULL;
|
|
||||||
if (!push_ascii_talloc(talloc_tos(), &tmpbuf2, s, &converted_size)) {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
ret = strlen(tmpbuf2);
|
|
||||||
TALLOC_FREE(tmpbuf2);
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool trim_char(char *s,char cfront,char cback)
|
bool trim_char(char *s,char cfront,char cback)
|
||||||
{
|
{
|
||||||
bool ret = false;
|
bool ret = false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user