1e5cb64569
The API looks like this on AIX: typedef int *atomic_p; int fetch_and_add(atomic_p addr, int value); The strange thing is that the xlc compiler ignores missing arguments by default. (It warns but doesn't fail to compile) As a result the value argument was just uninitialized memory, which means that the ref_cnt variable of struct heim_base, gets unpredictable values during heim_retain() and heim_release(), resulting in memory leaks. Signed-off-by: Stefan Metzmacher <metze@samba.org>