summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--cppu/source/uno/lbenv.cxx4
-rw-r--r--stoc/source/invocation_adapterfactory/iafactory.cxx2
2 files changed, 6 insertions, 0 deletions
diff --git a/cppu/source/uno/lbenv.cxx b/cppu/source/uno/lbenv.cxx
index 377b20b8531e..ef37aee9619e 100644
--- a/cppu/source/uno/lbenv.cxx
+++ b/cppu/source/uno/lbenv.cxx
@@ -190,6 +190,10 @@ inline void ObjectEntry::append(
::std::pair< Ptr2ObjectMap::iterator, bool > insertion(
pEnv->aPtr2ObjectMap.insert( Ptr2ObjectMap::value_type(
pInterface, this ) ) );
+ // No idea if the code above has side-effects and can't be just
+ // bypassed in the no-OSL_ASSERT case, so avoid "unused variable" like this instead.
+ (void) insertion;
+
OSL_ASSERT( insertion.second ||
(find( pInterface, 0 ) >= 0 &&
// points to the same object entry:
diff --git a/stoc/source/invocation_adapterfactory/iafactory.cxx b/stoc/source/invocation_adapterfactory/iafactory.cxx
index 02f715b933d1..72a880acf88a 100644
--- a/stoc/source/invocation_adapterfactory/iafactory.cxx
+++ b/stoc/source/invocation_adapterfactory/iafactory.cxx
@@ -863,6 +863,8 @@ Reference< XInterface > FactoryImpl::createAdapter(
{
pair< t_ptr_set::iterator, bool > insertion(
adapter_set->insert( pNew ) );
+ // Avoid unused variable warning
+ (void) insertion;
OSL_ASSERT( insertion.second );
that = pNew;
}