[PATCH] strv: Add l_strv_eq
by Andrew Zaborowski
---
ell/ell.sym | 1 +
ell/strv.c | 20 ++++++++++++++++++++
ell/strv.h | 1 +
3 files changed, 22 insertions(+)
diff --git a/ell/ell.sym b/ell/ell.sym
index 9fcf334..10865af 100644
--- a/ell/ell.sym
+++ b/ell/ell.sym
@@ -40,6 +40,7 @@ global:
l_strv_append_printf;
l_strv_append_vprintf;
l_strv_copy;
+ l_strv_eq;
/* utf8 */
l_ascii_table;
l_utf8_get_codepoint;
diff --git a/ell/strv.c b/ell/strv.c
index 3df47be..1343519 100644
--- a/ell/strv.c
+++ b/ell/strv.c
@@ -359,3 +359,23 @@ LIB_EXPORT char **l_strv_copy(char **str_array)
return copy;
}
+
+/**
+ * l_strv_eq:
+ * @a: a %NULL terminated array of strings or %NULL
+ * @b: another %NULL terminated array of strings or %NULL
+ *
+ * Returns: Whether @a and @b's contents are identical, including the
+ * order, or @a and @b are both %NULL.
+ */
+LIB_EXPORT bool l_strv_eq(char **a, char **b)
+{
+ if (!a || !b)
+ return a == b;
+
+ for (; *a; a++, b++)
+ if (!*b || strcmp(*a, *b))
+ return false;
+
+ return !*b;
+}
diff --git a/ell/strv.h b/ell/strv.h
index e673fec..db15cc7 100644
--- a/ell/strv.h
+++ b/ell/strv.h
@@ -46,6 +46,7 @@ char **l_strv_append_vprintf(char **str_array, const char *format,
va_list args)
__attribute__((format(printf, 2, 0)));
char **l_strv_copy(char **str_array);
+bool l_strv_eq(char **a, char **b);
#ifdef __cplusplus
}
--
2.30.2
4 months
Juego mod apk descargar
by mildredselinaer@gmail.com
En tu juego Mod APK descargar, puedes ser un tipo abusando a una niña. Puedes elegir cómo quieres tratar al adulto sin género. Los resultados son muy diferentes, y puede optar por vengarse del tipo, o puede tomarlo lento. Hay muchas razones por las que deberías jugar este juego. Puedes tener una experiencia traviesa, o una sexy. Descarga los últimos juegos de mod en https://modpree.com/
Tu novio es un excelente ejemplo de esto. Esta novela visual le permite elegir lo que le sucede a la niña y avanza con la historia. ¡Te sorprenderás por las reacciones Shell a las decisiones que haces! Este es un juego que seguramente dejará tu cabello al final. ¡Es necesario tener para cualquier mujer! Y encontrarás mucho más para amar en gamemode apk.com.
Juego Mod APK Descargar es una excelente manera de experimentar lo mejor de Android Gaming. Con los mods correctos, puede jugar juegos populares y obtener todas las características que ha estado soñando. También es una excelente manera de obtener versiones gratuitas de las aplicaciones. La lista de juegos y aplicaciones disponibles es infinita, y la selección siempre está creciendo. Incluso puede encontrar versiones falsas de IOS de juegos populares y aplicaciones. Entonces, si desea experimentar lo mejor de ambos mundos, ¡este es el sitio para visitar!
6 months, 2 weeks
[PATCH] unit: add asserts to unitset test
by James Prestwood
To satisfy static analysis add a few more return checks
---
unit/test-uintset.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/unit/test-uintset.c b/unit/test-uintset.c
index 0918ef2..31dc274 100644
--- a/unit/test-uintset.c
+++ b/unit/test-uintset.c
@@ -370,18 +370,18 @@ static void test_uintset_size(const void *user_data)
assert(l_uintset_size(set) == 0);
- for (i = 0; i < 32; i++) {
- l_uintset_put(set, i);
+ for (i = 1; i < 32; i++) {
+ assert(l_uintset_put(set, i));
assert(l_uintset_size(set) == i);
}
assert(l_uintset_size(set) == i - 1);
- l_uintset_take(set, 10);
+ assert(l_uintset_take(set, 10));
assert(l_uintset_size(set) == i - 2);
- for (i = 0; i < 32; i++)
- l_uintset_take(set, i);
+ for (i = 1; i < 32; i++)
+ assert(l_uintset_take(set, i));
assert(l_uintset_size(set) == 0);
}
--
2.31.1
6 months, 3 weeks
[PATCH] genl: add l_genl_family_request_sent
by James Prestwood
Returns true if a request has been sent to genl. This is useful
for knowning if a l_genl_family_cancel call will have any effect
besides NULLing out the callback.
---
ell/ell.sym | 1 +
ell/genl.c | 16 ++++++++++++++++
ell/genl.h | 1 +
3 files changed, 18 insertions(+)
diff --git a/ell/ell.sym b/ell/ell.sym
index febb855..51db458 100644
--- a/ell/ell.sym
+++ b/ell/ell.sym
@@ -342,6 +342,7 @@ global:
l_genl_family_send;
l_genl_family_dump;
l_genl_family_cancel;
+ l_genl_family_request_sent;
l_genl_family_register;
l_genl_family_unregister;
/* hwdb */
diff --git a/ell/genl.c b/ell/genl.c
index 7d79ef5..9a52be4 100644
--- a/ell/genl.c
+++ b/ell/genl.c
@@ -1960,6 +1960,22 @@ done:
return true;
}
+LIB_EXPORT bool l_genl_family_request_sent(struct l_genl_family *family,
+ unsigned int id)
+{
+ struct l_genl *genl;
+
+ if (unlikely(!family) || unlikely(!id))
+ return false;
+
+ genl = family->genl;
+ if (!genl)
+ return false;
+
+ return l_queue_find(genl->pending_list, match_request_id,
+ L_UINT_TO_PTR(id)) != NULL;
+}
+
static void add_membership(struct l_genl *genl, struct genl_mcast *mcast)
{
int group = mcast->id;
diff --git a/ell/genl.h b/ell/genl.h
index 7550bf8..7e5b7bb 100644
--- a/ell/genl.h
+++ b/ell/genl.h
@@ -141,6 +141,7 @@ unsigned int l_genl_family_dump(struct l_genl_family *family,
void *user_data,
l_genl_destroy_func_t destroy);
bool l_genl_family_cancel(struct l_genl_family *family, unsigned int id);
+bool l_genl_family_request_sent(struct l_genl_family *family, unsigned int id);
unsigned int l_genl_family_register(struct l_genl_family *family,
const char *group, l_genl_msg_func_t callback,
--
2.31.1
6 months, 3 weeks