]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
BUILD: pools: fix build with DEBUG_FAIL_ALLOC
authorWilly Tarreau <w@1wt.eu>
Mon, 19 Apr 2021 16:36:48 +0000 (18:36 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 19 Apr 2021 16:36:48 +0000 (18:36 +0200)
Amaury noticed that I managed to break the build of DEBUG_FAIL_ALLOC
for the second time with 207c09509 ("MINOR: pools: move the fault
injector to __pool_alloc()"). The joy of endlessly reworking patch
sets... No backport is needed, that was in the just merged cleanup
series.

include/haproxy/pool.h
src/pool.c

index 54ec9334689c581af33c9d042773be1cf3b2fffb..a7d77e4c6b82b40ecd334b98589920173ba27a52 100644 (file)
@@ -63,6 +63,7 @@ struct pool_head *create_pool(char *name, unsigned int size, unsigned int flags)
 void create_pool_callback(struct pool_head **ptr, char *name, unsigned int size);
 void *pool_destroy(struct pool_head *pool);
 void pool_destroy_all();
+int mem_should_fail(const struct pool_head *pool);
 
 
 #ifdef CONFIG_HAP_POOLS
index 88c579b6d5cc7fcf822ddf4aa027386bfc9736d3..70095021ad3fbe21d2e86c330b60e7b45218a820 100644 (file)
@@ -38,7 +38,6 @@ int mem_poison_byte = -1;
 
 #ifdef DEBUG_FAIL_ALLOC
 static int mem_fail_rate = 0;
-static int mem_should_fail(const struct pool_head *);
 #endif
 
 /* Try to find an existing shared pool with the same characteristics and