# HG changeset patch # User Mike Becker # Date 1730481439 -3600 # Node ID b5814aac3a769472fb13d85271586087182ad18c # Parent a58f602ed2fe07004e1ee22ce2dfc7b64e7665c1 add assertion that triggers when cx_array_copy() stops working for NULL arrays diff -r a58f602ed2fe -r b5814aac3a76 src/array_list.c --- a/src/array_list.c Fri Nov 01 18:16:32 2024 +0100 +++ b/src/array_list.c Fri Nov 01 18:17:19 2024 +0100 @@ -105,6 +105,7 @@ // determine capacity size_t cap = capacity == NULL ? *size : *capacity; + assert(*target != NULL || cap == 0); // check if resize is required size_t minsize = index + elem_count;