The FreeRADIUS server $Id: a4e7f8c94e8038b7627bcf52356b7ed15955c1d7 $
Loading...
Searching...
No Matches
Functions | Variables
talloc_tests.c File Reference

Tests for talloc and FreeRADIUS talloc utility functions. More...

#include "acutest_common_init.h"
#include "acutest_helpers.h"
#include <freeradius-devel/util/talloc.h>
#include <freeradius-devel/util/math.h>
+ Include dependency graph for talloc_tests.c:

Go to the source code of this file.

Functions

static int native_destructor (int *ptr)
 
static size_t pool_chunk_footprint (size_t size)
 
static int test_fr_destructor_func (UNUSED void *fire_ctx, void *uctx)
 
static void test_talloc_aligned_array (void)
 
static void test_talloc_array (void)
 
static void test_talloc_array_null_terminate (void)
 
static void test_talloc_asprintf (void)
 
static void test_talloc_basic (void)
 
static void test_talloc_bstr_append (void)
 
static void test_talloc_bstr_realloc (void)
 
static void test_talloc_bstrndup (void)
 
static void test_talloc_decrease_ref_count (void)
 
static void test_talloc_deep_hierarchy (void)
 
static void test_talloc_destructor_add (void)
 
static void test_talloc_find_parent_byname (void)
 
static void test_talloc_free (void)
 
static void test_talloc_free_children (void)
 
static void test_talloc_get_size (void)
 
static void test_talloc_hdr_size (void)
 
static void test_talloc_increase_ref_count (void)
 
static void test_talloc_is_parent (void)
 
static void test_talloc_link_ctx (void)
 
static void test_talloc_memcmp_bstr (void)
 
static void test_talloc_memdup (void)
 
static void test_talloc_move (void)
 
static void test_talloc_naming (void)
 
static void test_talloc_parent (void)
 
static void test_talloc_pool (void)
 
static void test_talloc_pool_used (void)
 
static void test_talloc_realloc_zero (void)
 
static void test_talloc_reference (void)
 
static void test_talloc_reparent (void)
 
static void test_talloc_set_destructor (void)
 
static void test_talloc_steal (void)
 
static void test_talloc_strdup (void)
 
static void test_talloc_strndup_append (void)
 
static void test_talloc_total_size (void)
 
static void test_talloc_typed_asprintf (void)
 
static void test_talloc_typed_memdup (void)
 
static void test_talloc_typed_strdup (void)
 
static void test_talloc_typed_strndup (void)
 
static void test_talloc_zero (void)
 

Variables

static int fr_destructor_called
 
static void const * fr_destructor_uctx
 
static int native_destructor_count
 
 TEST_LIST
 

Detailed Description

Tests for talloc and FreeRADIUS talloc utility functions.

Definition in file talloc_tests.c.

Function Documentation

◆ native_destructor()

static int native_destructor ( int *  ptr)
static

Definition at line 302 of file talloc_tests.c.

+ Here is the caller graph for this function:

◆ pool_chunk_footprint()

static size_t pool_chunk_footprint ( size_t  size)
static

Definition at line 1107 of file talloc_tests.c.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ test_fr_destructor_func()

static int test_fr_destructor_func ( UNUSED void *  fire_ctx,
void *  uctx 
)
static

Definition at line 946 of file talloc_tests.c.

+ Here is the caller graph for this function:

◆ test_talloc_aligned_array()

static void test_talloc_aligned_array ( void  )
static

Definition at line 1085 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_array()

static void test_talloc_array ( void  )
static

Definition at line 90 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_array_null_terminate()

static void test_talloc_array_null_terminate ( void  )
static

Definition at line 916 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_asprintf()

static void test_talloc_asprintf ( void  )
static

Definition at line 371 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_basic()

static void test_talloc_basic ( void  )
static

Definition at line 35 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_bstr_append()

static void test_talloc_bstr_append ( void  )
static

Definition at line 822 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_bstr_realloc()

static void test_talloc_bstr_realloc ( void  )
static

Definition at line 846 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_bstrndup()

static void test_talloc_bstrndup ( void  )
static

Definition at line 796 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_decrease_ref_count()

static void test_talloc_decrease_ref_count ( void  )
static

Definition at line 1054 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_deep_hierarchy()

static void test_talloc_deep_hierarchy ( void  )
static

Definition at line 626 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_destructor_add()

static void test_talloc_destructor_add ( void  )
static

Definition at line 953 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_find_parent_byname()

static void test_talloc_find_parent_byname ( void  )
static

Definition at line 522 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_free()

static void test_talloc_free ( void  )
static

Definition at line 131 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_free_children()

static void test_talloc_free_children ( void  )
static

Definition at line 432 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_get_size()

static void test_talloc_get_size ( void  )
static

Definition at line 498 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_hdr_size()

static void test_talloc_hdr_size ( void  )
static

Definition at line 1004 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_increase_ref_count()

static void test_talloc_increase_ref_count ( void  )
static

Definition at line 676 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_is_parent()

static void test_talloc_is_parent ( void  )
static

Definition at line 549 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_link_ctx()

static void test_talloc_link_ctx ( void  )
static

Definition at line 988 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_memcmp_bstr()

static void test_talloc_memcmp_bstr ( void  )
static

Definition at line 872 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_memdup()

static void test_talloc_memdup ( void  )
static

Definition at line 605 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_move()

static void test_talloc_move ( void  )
static

Definition at line 245 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_naming()

static void test_talloc_naming ( void  )
static

Definition at line 152 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_parent()

static void test_talloc_parent ( void  )
static

Definition at line 181 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_pool()

static void test_talloc_pool ( void  )
static

Definition at line 401 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_pool_used()

static void test_talloc_pool_used ( void  )
static

Definition at line 1126 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_realloc_zero()

static void test_talloc_realloc_zero ( void  )
static

Definition at line 1021 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_reference()

static void test_talloc_reference ( void  )
static

Definition at line 269 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_reparent()

static void test_talloc_reparent ( void  )
static

Definition at line 577 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_set_destructor()

static void test_talloc_set_destructor ( void  )
static

Definition at line 310 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_steal()

static void test_talloc_steal ( void  )
static

Definition at line 211 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_strdup()

static void test_talloc_strdup ( void  )
static

Definition at line 343 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_strndup_append()

static void test_talloc_strndup_append ( void  )
static

Definition at line 651 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_total_size()

static void test_talloc_total_size ( void  )
static

Definition at line 465 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_typed_asprintf()

static void test_talloc_typed_asprintf ( void  )
static

Definition at line 773 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_typed_memdup()

static void test_talloc_typed_memdup ( void  )
static

Definition at line 895 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_typed_strdup()

static void test_talloc_typed_strdup ( void  )
static

Definition at line 719 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_typed_strndup()

static void test_talloc_typed_strndup ( void  )
static

Definition at line 749 of file talloc_tests.c.

+ Here is the call graph for this function:

◆ test_talloc_zero()

static void test_talloc_zero ( void  )
static

Definition at line 63 of file talloc_tests.c.

+ Here is the call graph for this function:

Variable Documentation

◆ fr_destructor_called

int fr_destructor_called
static

Definition at line 943 of file talloc_tests.c.

◆ fr_destructor_uctx

void const* fr_destructor_uctx
static

Definition at line 944 of file talloc_tests.c.

◆ native_destructor_count

int native_destructor_count
static

Definition at line 300 of file talloc_tests.c.

◆ TEST_LIST

TEST_LIST

Definition at line 1175 of file talloc_tests.c.