zabbix-agent2/src/libs/zbxtrends/cache.c
/******************************************************************************
 *                                                                            *
 * Function: tfc_reserve_slot                                                 *
 *                                                                            *
 * Purpose: ensure there is a free slot available                             *
 *                                                                            *
 ******************************************************************************/
tfc_reserve_slot

Purpose: ensure there is a free slot available
tfc_reserve_slot Purpose : ensure there is a free slot available
static void	tfc_reserve_slot(void)
{
	if (UINT32_MAX == cache->free_head && cache->slots_num == cache->free_slot)
	{
		if (UINT32_MAX == cache->lru_head)
		{
			THIS_SHOULD_NEVER_HAPPEN;
			exit(1);
		}
		tfc_free_data(&cache->slots[cache->lru_head].data);
	}
}
static void tfc_reserve_slot ( void ) { if ( UINT32_MAX == cache -> free_head && cache -> slots_num == cache -> free_slot ) { if ( UINT32_MAX == cache -> lru_head ) { THIS_SHOULD_NEVER_HAPPEN ; exit ( 1 ) ; } tfc_free_data ( & cache -> slots [ cache -> lru_head ] . data ) ; } }
Function: tfc_reserve_slot                                                 
                                                                            
 Purpose: ensure there is a free slot available
Function : tfc_reserve_slot Purpose : ensure there is a free slot available