summaryrefslogtreecommitdiff
path: root/cppu/source/uno/IdentityMapping.cxx
diff options
context:
space:
mode:
authorNorbert Thiebaud <nthiebaud@gmail.com>2012-09-16 02:00:14 -0500
committerNorbert Thiebaud <nthiebaud@gmail.com>2012-09-17 14:26:12 +0000
commit195f17ee40003f0ff74d08fecf5d68afe9cb1036 (patch)
treebeca88d96ae704d4ecb03defd9390b1a05a24c47 /cppu/source/uno/IdentityMapping.cxx
parentc9d3373dadc1fbb36a6cf62661f0ec59b313d74b (diff)
migrate some of the biggest consumer of osl_*InterlockedCount to osl_atomic
Change-Id: I0e6992afbeffaf3b993e6630fb396d93012890e0 Reviewed-on: https://gerrit.libreoffice.org/632 Tested-by: Norbert Thiebaud <nthiebaud@gmail.com> Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'cppu/source/uno/IdentityMapping.cxx')
-rw-r--r--cppu/source/uno/IdentityMapping.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/cppu/source/uno/IdentityMapping.cxx b/cppu/source/uno/IdentityMapping.cxx
index f3b0f440565e..bf59a8534959 100644
--- a/cppu/source/uno/IdentityMapping.cxx
+++ b/cppu/source/uno/IdentityMapping.cxx
@@ -47,7 +47,7 @@ static void SAL_CALL s_acquire(uno_Mapping * pMapping) SAL_THROW(())
{
static rtl::OUString s_purpose;
- if (1 == ::osl_incrementInterlockedCount(&static_cast<IdentityMapping *>(pMapping)->m_nRef))
+ if (1 == osl_atomic_increment(&static_cast<IdentityMapping *>(pMapping)->m_nRef))
{
uno_registerMapping(
&pMapping,
@@ -60,7 +60,7 @@ static void SAL_CALL s_acquire(uno_Mapping * pMapping) SAL_THROW(())
static void SAL_CALL s_release(uno_Mapping * pMapping) SAL_THROW(())
{
- if (!::osl_decrementInterlockedCount(&static_cast<IdentityMapping *>(pMapping )->m_nRef))
+ if (!osl_atomic_decrement(&static_cast<IdentityMapping *>(pMapping )->m_nRef))
uno_revokeMapping(pMapping);
}