Crash due to bad memory usage when calling a function taking an inout array with length parameter and transfer full
Basically when calling something like (as highlighted by gobject-introspection!407):
/**
* gi_marshalling_tests_length_array_of_gstrv_transfer_full_inout:
* @array_inout: (array length=inout_length) (inout) (element-type GStrv) (transfer full):
* @inout_length: (inout):
*/
void
gi_marshalling_tests_length_array_of_gstrv_transfer_full_inout (GStrv **array_inout, size_t *inout_length)
{
GStrv *array = g_new0 (GStrv, 4);
GStrv values;
g_assert_nonnull (inout_length);
g_assert_nonnull (array_inout);
gi_marshalling_tests_length_array_of_gstrv_transfer_full_in (
g_steal_pointer (array_inout), *inout_length);
values = g_new0 (gchar *, 5);
values[0] = g_strdup ("-1");
values[1] = g_strdup ("0");
values[2] = g_strdup ("1");
values[3] = g_strdup ("2");
values[4] = NULL;
array[0] = g_steal_pointer (&values);
values = g_new0 (gchar *, 5);
values[0] = g_strdup ("-1");
values[1] = g_strdup ("3");
values[2] = g_strdup ("4");
values[3] = g_strdup ("5");
values[4] = NULL;
array[1] = g_steal_pointer (&values);
values = g_new0 (gchar *, 5);
values[0] = g_strdup ("-1");
values[1] = g_strdup ("6");
values[2] = g_strdup ("7");
values[3] = g_strdup ("8");
values[4] = NULL;
array[2] = g_steal_pointer (&values);
values = g_new0 (gchar *, 5);
values[0] = g_strdup ("-1");
values[1] = g_strdup ("9");
values[2] = g_strdup ("10");
values[3] = g_strdup ("11");
values[4] = NULL;
array[3] = g_steal_pointer (&values);
*array_inout = (GStrv *) array;
*inout_length = 4;
}