mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-25 19:52:10 +01:00
gptrarray: Correctly set copied array length in g_ptr_array_copy()
The allocation size was set correctly before, but not the array length, so the copied array appeared to have zero elements. Signed-off-by: Philip Withnall <withnall@endlessm.com>
This commit is contained in:
parent
1ac8d50331
commit
b4943aa360
@ -1051,6 +1051,8 @@ g_ptr_array_copy (GPtrArray *array,
|
||||
array->len * sizeof (*array->pdata));
|
||||
}
|
||||
|
||||
new_array->len = array->len;
|
||||
|
||||
return new_array;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user