|  | The FreeRADIUS server $Id: 15bac2a4c627c01d1aa2047687b3418955ac7f00 $
    | 
#include <freeradius-devel/server/base.h>#include <freeradius-devel/io/control.h>#include <freeradius-devel/util/debug.h>#include <freeradius-devel/util/syserror.h>#include <freeradius-devel/util/talloc.h>#include <freeradius-devel/util/time.h>#include <sys/event.h>#include <stdio.h>#include <string.h>#include <pthread.h> Include dependency graph for control_test.c:
 Include dependency graph for control_test.c:Go to the source code of this file.
| Data Structures | |
| struct | master_ctx_t | 
| struct | worker_args_t | 
| Macros | |
| #define | CONTROL_MAGIC 0xabcd6809 | 
| #define | MEM(x) if (!(x)) { fprintf(stderr, "%s[%u] OUT OF MEMORY\n", __FILE__, __LINE__); _exit(EXIT_FAILURE); } | 
| #define | MPRINT1 if (debug_lvl) printf | 
| #define | MPRINT2 if (debug_lvl >= 2) printf | 
| #define | MPRINT3 if (debug_lvl >= 3) printf | 
| Functions | |
| static void * | control_master (UNUSED void *arg) | 
| static void * | control_worker (void *arg) | 
| int | main (int argc, char *argv[]) | 
| static void | recv_control_callback (void *ctx, void const *data, size_t data_size, UNUSED fr_time_t now) | 
| static NEVER_RETURNS void | usage (void) | 
| Variables | |
| static fr_atomic_queue_t ** | aq | 
| static int | aq_size = 16 | 
| static fr_control_t ** | control = NULL | 
| static int | debug_lvl = 0 | 
| static fr_event_list_t * | el = NULL | 
| static size_t | max_messages = 10 | 
| static size_t | num_aq = 1 | 
| static size_t | num_workers = 1 | 
| static bool | single_aq = true | 
| struct master_ctx_t | 
Definition at line 82 of file control_test.c.
| Data Fields | ||
|---|---|---|
| size_t | num_messages | |
| struct my_message_t | 
Definition at line 76 of file control_test.c.
| Data Fields | ||
|---|---|---|
| size_t | counter | |
| uint32_t | header | |
| size_t | worker | |
| struct worker_args_t | 
Definition at line 48 of file control_test.c.
 Collaboration diagram for worker_args_t:
 Collaboration diagram for worker_args_t:| Data Fields | ||
|---|---|---|
| size_t | id | |
| fr_ring_buffer_t * | rb | |
| #define CONTROL_MAGIC 0xabcd6809 | 
Definition at line 46 of file control_test.c.
| #define MEM | ( | x | ) | if (!(x)) { fprintf(stderr, "%s[%u] OUT OF MEMORY\n", __FILE__, __LINE__); _exit(EXIT_FAILURE); } | 
Definition at line 42 of file control_test.c.
Definition at line 43 of file control_test.c.
Definition at line 44 of file control_test.c.
Definition at line 45 of file control_test.c.
| 
 | static | 
| 
 | static | 
| int main | ( | int | argc, | 
| char * | argv[] | ||
| ) | 
| 
 | static | 
| 
 | static | 
Definition at line 54 of file control_test.c.
| 
 | static | 
Definition at line 57 of file control_test.c.
| 
 | static | 
Definition at line 58 of file control_test.c.
| 
 | static | 
Definition at line 53 of file control_test.c.
| 
 | static | 
Definition at line 59 of file control_test.c.
| 
 | static | 
Definition at line 55 of file control_test.c.
| 
 | static | 
Definition at line 61 of file control_test.c.
| 
 | static | 
Definition at line 56 of file control_test.c.
| 
 | static | 
Definition at line 60 of file control_test.c.
 1.9.8
 1.9.8