Remove duplicate 'strref_isempty'
This commit is contained in:
parent
e63ebdce91
commit
2f21e2a450
@ -19,11 +19,6 @@
|
||||
|
||||
static const char *astrblank = "";
|
||||
|
||||
static inline bool strref_is_empty(const struct strref *str)
|
||||
{
|
||||
return !str || !str->array || !str->len || !*str->array;
|
||||
}
|
||||
|
||||
int strref_cmp(const struct strref *str1, const char *str2)
|
||||
{
|
||||
size_t i = 0;
|
||||
|
@ -58,14 +58,9 @@ static inline void strref_add(struct strref *dst, const struct strref *t)
|
||||
dst->len += t->len;
|
||||
}
|
||||
|
||||
static inline bool strref_isempty(const struct strref *str)
|
||||
static inline bool strref_is_empty(const struct strref *str)
|
||||
{
|
||||
if (!str->array || !str->len)
|
||||
return true;
|
||||
if (!*str->array)
|
||||
return true;
|
||||
|
||||
return false;
|
||||
return !str || !str->array || !str->len || !*str->array;
|
||||
}
|
||||
|
||||
EXPORT int strref_cmp(const struct strref *str1, const char *str2);
|
||||
|
Loading…
x
Reference in New Issue
Block a user