regressions/ck_queue: Add coverage for previous regression.

ck_pring
Samy Al Bahra 12 years ago
parent 25658c4f5f
commit cff7b1b21f

@ -117,7 +117,7 @@ int
main(int argc, char *argv[])
{
pthread_t *thread;
struct test *n;
struct test *n, a, b;
struct test_list target;
int n_threads, i;
@ -156,6 +156,13 @@ main(int argc, char *argv[])
free(n);
}
CK_LIST_INSERT_HEAD(&head, &a, list_entry);
CK_LIST_INSERT_HEAD(&head, &b, list_entry);
CK_LIST_REMOVE(&a, list_entry);
if (CK_LIST_FIRST(&head) != &b)
ck_error("List is in invalid state.\n");
CK_LIST_REMOVE(&b, list_entry);
if (CK_LIST_EMPTY(&head) == false) {
ck_error("List is not empty after bulk removal.\n");
}

Loading…
Cancel
Save