]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
more linker hacks to get it to build
authorAlan T. DeKok <aland@freeradius.org>
Fri, 16 Jun 2017 12:43:59 +0000 (08:43 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Fri, 16 Jun 2017 12:43:59 +0000 (08:43 -0400)
src/tests/util/channel_test.c
src/tests/util/control_test.c
src/tests/util/worker_test.c

index 4ae8d82b4e90875308c0dd12d814f277c8ecf447..2381278a17615ed19427898d266a18a62d737eb5 100644 (file)
@@ -52,6 +52,31 @@ static int                   max_control_plane = 0;
 static int                     max_outstanding = 1;
 static bool                    touch_memory = false;
 
+/**********************************************************************/
+typedef struct rad_request REQUEST;
+REQUEST *request_alloc(UNUSED TALLOC_CTX *ctx);
+void verify_request(UNUSED char const *file, UNUSED int line, UNUSED REQUEST *request);
+void talloc_const_free(void const *ptr);
+
+REQUEST *request_alloc(UNUSED TALLOC_CTX *ctx)
+{
+       return NULL;
+}
+
+void verify_request(UNUSED char const *file, UNUSED int line, UNUSED REQUEST *request)
+{
+}
+
+void talloc_const_free(void const *ptr)
+{
+       void *tmp;
+       if (!ptr) return;
+
+       memcpy(&tmp, &ptr, sizeof(tmp));
+       talloc_free(tmp);
+}
+/**********************************************************************/
+
 static void NEVER_RETURNS usage(void)
 {
        fprintf(stderr, "usage: channel_test [OPTS]\n");
index 6dc4b54bcf53a85b4dac89d7a92d1c8159a2c0c5..632dc7e625363579dce5d56f6a92e3b1011a621e 100644 (file)
@@ -49,6 +49,31 @@ static int           aq_size = 16;
 static fr_control_t    *control = NULL;
 static fr_ring_buffer_t *rb = NULL;
 
+/**********************************************************************/
+typedef struct rad_request REQUEST;
+REQUEST *request_alloc(UNUSED TALLOC_CTX *ctx);
+void verify_request(UNUSED char const *file, UNUSED int line, UNUSED REQUEST *request);
+void talloc_const_free(void const *ptr);
+
+REQUEST *request_alloc(UNUSED TALLOC_CTX *ctx)
+{
+       return NULL;
+}
+
+void verify_request(UNUSED char const *file, UNUSED int line, UNUSED REQUEST *request)
+{
+}
+
+void talloc_const_free(void const *ptr)
+{
+       void *tmp;
+       if (!ptr) return;
+
+       memcpy(&tmp, &ptr, sizeof(tmp));
+       talloc_free(tmp);
+}
+/**********************************************************************/
+
 static void NEVER_RETURNS usage(void)
 {
        fprintf(stderr, "usage: control_test [OPTS]\n");
index e7910df278dc479303da3e29cbfb22b047bcb74e..f51d2b98a993d70af4bbc18a0b93cb3772e97b4f 100644 (file)
@@ -63,6 +63,31 @@ static int           num_workers = 1;
 static bool            quiet = false;
 static fr_schedule_worker_t workers[MAX_WORKERS];
 
+/**********************************************************************/
+typedef struct rad_request REQUEST;
+REQUEST *request_alloc(UNUSED TALLOC_CTX *ctx);
+void verify_request(UNUSED char const *file, UNUSED int line, UNUSED REQUEST *request);
+void talloc_const_free(void const *ptr);
+
+REQUEST *request_alloc(UNUSED TALLOC_CTX *ctx)
+{
+       return NULL;
+}
+
+void verify_request(UNUSED char const *file, UNUSED int line, UNUSED REQUEST *request)
+{
+}
+
+void talloc_const_free(void const *ptr)
+{
+       void *tmp;
+       if (!ptr) return;
+
+       memcpy(&tmp, &ptr, sizeof(tmp));
+       talloc_free(tmp);
+}
+/**********************************************************************/
+
 static void NEVER_RETURNS usage(void)
 {
        fprintf(stderr, "usage: worker_test [OPTS]\n");