]> git.kaiwu.me - haproxy.git/commit
BUILD: memory: fix free_list pointer declaration again for atomic CAS
authorWilly Tarreau <w@1wt.eu>
Sat, 20 Oct 2018 15:37:38 +0000 (17:37 +0200)
committerWilly Tarreau <w@1wt.eu>
Sat, 20 Oct 2018 15:37:38 +0000 (17:37 +0200)
commit7a6ad88b02d8b74c2488003afb1a7063043ddd2d
tree8d276e7641ba8504b16868a562379c27dc88920d
parented72d82827b60b266daaeeb0f1934c6fac76133a
BUILD: memory: fix free_list pointer declaration again for atomic CAS

Commit ac6c880 ("BUILD: memory: fix pointer declaration for atomic CAS")
attemtped to fix a build warning affecting the lock-free version of the
pool allocator. But the fix tried to hide the cause instead of addressing
it, thus clang still complains about (void **) not matching (void ***).

The real solution is to declare free_list (void **) and not to use a cast.
Now this builds fine with gcc/clang with and without threads.

No backport is needed.
include/common/memory.h