mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2025-12-28 14:30:07 +01:00
test/list: Fix test_xorg_list_del test
We never use child[2], so it's state is undefined. This issue seems to have existed since the test was first written:92788e677bSigned-off-by: Jeremy Huddleston Sequoia <jeremyhu@apple.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> (cherry picked from commitc75c947b6e)
This commit is contained in:
parent
dfc03ef3fd
commit
dd36e132fa
1 changed files with 2 additions and 2 deletions
|
|
@ -137,7 +137,7 @@ static void
|
|||
test_xorg_list_del(void)
|
||||
{
|
||||
struct parent parent = { 0 };
|
||||
struct child child[3];
|
||||
struct child child[2];
|
||||
struct child *c;
|
||||
|
||||
xorg_list_init(&parent.children);
|
||||
|
|
@ -178,8 +178,8 @@ test_xorg_list_del(void)
|
|||
xorg_list_add(&child[0].node, &parent.children);
|
||||
xorg_list_del(&parent.children);
|
||||
assert(xorg_list_is_empty(&parent.children));
|
||||
assert(!xorg_list_is_empty(&child[0].node));
|
||||
assert(!xorg_list_is_empty(&child[1].node));
|
||||
assert(!xorg_list_is_empty(&child[2].node));
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue