使用 UT_LIST_ADD_LAST(list, buf_pool->free, (&block->page));
/*******************************************************************//** Adds the node as the last element in a two-way linked list. @param NAME list name @param BASE the base node (not a pointer to it) @param N pointer to the node to be added to the list */ #define UT_LIST_ADD_LAST(NAME, BASE, N)\ {\ ut_ad(N != NULL);\ ((BASE).count)++;\ ((N)->NAME).prev = (BASE).end;\ ((N)->NAME).next = NULL;\ if ((BASE).end != NULL) {\ ut_ad((BASE).end != (N));\ (((BASE).end)->NAME).next = (N);\ }\ (BASE).end = (N);\ if ((BASE).start == NULL) {\ (BASE).start = (N);\ }\ }\