diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-02-18 09:49:22 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-02-18 09:49:22 +0100 |
commit | 765efd36fcadbc5df32f8fc2d7e8f4caf332ffbc (patch) | |
tree | 62c9fdcf567ef28c4f67f4a2eabc0802207e72ff | |
parent | f471fe7badd582ca64e452790b5ac46c365b8931 (diff) |
DBG_ASSERT -> assert
The only caller of GetResourceSkipHeader (BitmapEx ctor in
vcl/source/gdi/bitmapex.cxx) unconditionally expects *ppResMgr to be non-null
after the call.
Change-Id: I17e71df81019de5b78c4356c7aec967c50a5a6ae
-rw-r--r-- | tools/source/rc/resmgr.cxx | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/tools/source/rc/resmgr.cxx b/tools/source/rc/resmgr.cxx index 27d0cd71b9d0..6e0f34842254 100644 --- a/tools/source/rc/resmgr.cxx +++ b/tools/source/rc/resmgr.cxx @@ -1075,15 +1075,11 @@ void * ResMgr::GetResourceSkipHeader( const ResId& rResId, ResMgr ** ppResMgr ) { osl::Guard<osl::Mutex> aGuard( getResMgrMutex() ); - DBG_ASSERT( rResId.GetResMgr(), "illegal ResId without ResMgr" ); *ppResMgr = rResId.GetResMgr(); - if( *ppResMgr ) - { - (*ppResMgr)->GetResource( rResId ); - (*ppResMgr)->Increment( sizeof( RSHEADER_TYPE ) ); - return (*ppResMgr)->GetClass(); - } - return getEmptyBuffer(); + assert(*ppResMgr != nullptr); + (*ppResMgr)->GetResource( rResId ); + (*ppResMgr)->Increment( sizeof( RSHEADER_TYPE ) ); + return (*ppResMgr)->GetClass(); } void ResMgr::PopContext( const Resource* pResObj ) |