mirror of
https://github.com/nunuhara/xsystem4.git
synced 2026-10-05 21:37:59 +03:00
Add an early return to array_copy()
This fixes test_array_copy() broken by 0274052.
This commit is contained in:
@@ -369,6 +369,8 @@ static bool array_index_ok(struct page *array, int i)
|
||||
|
||||
void array_copy(struct page *dst, int dst_i, struct page *src, int src_i, int n)
|
||||
{
|
||||
if (n <= 0)
|
||||
return;
|
||||
if (!dst || !src)
|
||||
ERROR("Array is NULL");
|
||||
if (dst->type != ARRAY_PAGE || src->type != ARRAY_PAGE)
|
||||
|
||||
Reference in New Issue
Block a user