/* pop an existing item off the free queue, or create a new one  */
static lv_lru_item_t * lv_lru_pop_or_create_item(lv_lru_t *cache)
/* pop an existing item off the free queue, or create a new one  */
static lv_lru_item_t * lv_lru_pop_or_create_item(lv_lru_t *cache)
{
    lv_lru_item_t * item = NULL;
    if(cache->free_items) {
        item = cache->free_items;
        cache->free_items = item->next;
        lv_memset_00(item, sizeof(lv_lru_item_t));
    }
    else {
        item = (lv_lru_item_t *) lv_mem_alloc(sizeof(lv_lru_item_t));
        lv_memset_00(item, sizeof(lv_lru_item_t));
    }
    return item;
}