summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authortrawick <trawick@13f79535-47bb-0310-9956-ffa450edef68>2003-12-04 20:06:03 +0000
committertrawick <trawick@13f79535-47bb-0310-9956-ffa450edef68>2003-12-04 20:06:03 +0000
commit37ddc5264c4b0af63f625412457b8ca5559c5267 (patch)
treed37fbaf861b7975ed041d57b63bb7fe57246105d /include
parentd48b7138eb0c41ec8da1de3c5afe94f5aeee8cd0 (diff)
downloadlibapr-37ddc5264c4b0af63f625412457b8ca5559c5267.tar.gz
apr_atomic_add32() and apr_atomic_inc32() now return values (the old value)
Submitted by: gregames (all the hard bits) and trawick git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@64808 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'include')
-rw-r--r--include/apr_atomic.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/apr_atomic.h b/include/apr_atomic.h
index 3750429cf..c3a25bdb1 100644
--- a/include/apr_atomic.h
+++ b/include/apr_atomic.h
@@ -107,8 +107,9 @@ APR_DECLARE(void) apr_atomic_set32(volatile apr_uint32_t *mem, apr_uint32_t val)
* atomically add 'val' to an apr_uint32_t
* @param mem pointer to the object
* @param val amount to add
+ * @return old value pointed to by mem
*/
-APR_DECLARE(void) apr_atomic_add32(volatile apr_uint32_t *mem, apr_uint32_t val);
+APR_DECLARE(apr_uint32_t) apr_atomic_add32(volatile apr_uint32_t *mem, apr_uint32_t val);
/**
* atomically subtract 'val' from an apr_uint32_t
@@ -120,8 +121,9 @@ APR_DECLARE(void) apr_atomic_sub32(volatile apr_uint32_t *mem, apr_uint32_t val)
/**
* atomically increment an apr_uint32_t by 1
* @param mem pointer to the object
+ * @return old value pointed to by mem
*/
-APR_DECLARE(void) apr_atomic_inc32(volatile apr_uint32_t *mem);
+APR_DECLARE(apr_uint32_t) apr_atomic_inc32(volatile apr_uint32_t *mem);
/**
* atomically decrement an apr_uint32_t by 1