diff options
author | Tor Lillqvist <tml@iki.fi> | 2012-07-23 14:51:53 +0300 |
---|---|---|
committer | Tor Lillqvist <tml@iki.fi> | 2012-07-23 15:12:21 +0300 |
commit | 4b5f1d7b2d095e4b41434658b376b6de422bf573 (patch) | |
tree | c4c2a1b18600c62b912fca80a31137f468e56709 | |
parent | 9d1263d108244c172e682624557ca4d23ddfcd10 (diff) |
WaE: unused variable
Change-Id: Ie355701716c7106ef2afd76ae8b6544a00ac474c
-rw-r--r-- | cppu/source/uno/lbenv.cxx | 4 | ||||
-rw-r--r-- | stoc/source/invocation_adapterfactory/iafactory.cxx | 2 |
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; } |