[at-spi2-core: 8/10] bitarray_to_seq(): g_realloc() can't fail; don't assume it's like realloc()
- From: Federico Mena Quintero <federico src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [at-spi2-core: 8/10] bitarray_to_seq(): g_realloc() can't fail; don't assume it's like realloc()
- Date: Tue, 5 Jul 2022 00:28:52 +0000 (UTC)
commit e214ff95a4d88b29a76aabf550e40d4217131d89
Author: Federico Mena Quintero <federico gnome org>
Date: Mon Jul 4 19:10:19 2022 -0500
bitarray_to_seq(): g_realloc() can't fail; don't assume it's like realloc()
atk-adaptor/adaptors/collection-adaptor.c | 4 ----
1 file changed, 4 deletions(-)
---
diff --git a/atk-adaptor/adaptors/collection-adaptor.c b/atk-adaptor/adaptors/collection-adaptor.c
index c1c98be4..f53acb39 100644
--- a/atk-adaptor/adaptors/collection-adaptor.c
+++ b/atk-adaptor/adaptors/collection-adaptor.c
@@ -622,8 +622,6 @@ bitarray_to_seq (dbus_uint32_t *array, int array_count, int **ret)
int i, j;
int *out = (int *) g_malloc (out_size * sizeof (int));
- if (!out)
- return FALSE;
for (i = 0; i < array_count; i++)
{
for (j = 0; j < 32; j++)
@@ -634,8 +632,6 @@ bitarray_to_seq (dbus_uint32_t *array, int array_count, int **ret)
{
out_size <<= 1;
out = (int *) g_realloc (out, out_size * sizeof (int));
- if (!out)
- return FALSE;
}
out[out_count++] = i * 32 + j;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]