| 90 | ulong elements; /* The count of items in the Queue */ |
| 91 | |
| 92 | void push_back(T *payload) |
| 93 | { |
| 94 | struct queue_item *new_item; |
| 95 | |
| 96 | new_item= (struct queue_item *) my_malloc(sizeof(struct queue_item), MYF(0)); |
| 97 | |
| 98 | new_item->payload= payload; |
| 99 | |
| 100 | if (first == NULL) |
| 101 | first= new_item; |
| 102 | if (last != NULL) |
| 103 | { |
| 104 | DBUG_ASSERT(last->next == NULL); |
| 105 | last->next= new_item; |
| 106 | } |
| 107 | new_item->previous= last; |
| 108 | new_item->next= NULL; |
| 109 | last= new_item; |
| 110 | |
| 111 | elements++; |
| 112 | } |
| 113 | |
| 114 | T *pop() |
| 115 | { |
nothing calls this directly
no test coverage detected