mirror of https://github.com/OISF/suricata
atomics: change SC_ATOMIC_ADD to 'fetch_add'
Until this point the SC_ATOMIC_ADD macro pointed to a 'add_fetch' intrinsic. This patch changes it to a 'fetch_add'. There are 2 reasons for this: 1. C11 stdatomics.h has only 'atomic_fetch_add' and no 'add_fetch' So this patch prepares for adding support for C11 atomics. 2. It was not consistent with SC_ATOMIC_SUB, which did use 'fetch_sub' and not 'sub_fetch'. Most callers are not using the return value, so these are unaffected. The callers that do use the return value are updated.pull/4832/head
parent
109b2ae551
commit
531ff3ddec
Loading…
Reference in New Issue