Kaydet (Commit) dbd675df authored tarafından Fridrich Štrba's avatar Fridrich Štrba

Some "cast from ... to ... loses precision fixes"

Change-Id: Ib1d827bfa224e8708fd1e41b1ad213bcfef9a012
üst 57d88588
......@@ -74,8 +74,8 @@ void NumberedCollection::setUntitledPrefix(const OUString& sPrefix)
if ( ! xComponent.is ())
throw css::lang::IllegalArgumentException (OUString(ERRMSG_INVALID_COMPONENT_PARAM), m_xOwner.get(), 1);
long pComponent = (long) xComponent.get ();
TNumberedItemHash::const_iterator pIt = m_lComponents.find (pComponent);
sal_IntPtr pComponent = (sal_IntPtr) xComponent.get ();
TNumberedItemHash::const_iterator pIt = m_lComponents.find (pComponent);
// a) component already exists - return it's number directly
if (pIt != m_lComponents.end())
......@@ -150,8 +150,8 @@ void SAL_CALL NumberedCollection::releaseNumberForComponent(const css::uno::Refe
if ( ! xComponent.is ())
throw css::lang::IllegalArgumentException (OUString(ERRMSG_INVALID_COMPONENT_PARAM), m_xOwner.get(), 1);
long pComponent = (long) xComponent.get ();
TNumberedItemHash::iterator pIt = m_lComponents.find (pComponent);
sal_IntPtr pComponent = (sal_IntPtr) xComponent.get ();
TNumberedItemHash::iterator pIt = m_lComponents.find (pComponent);
// a) component exists and will be removed
if (pIt != m_lComponents.end())
......
......@@ -1235,9 +1235,9 @@ sal_uInt32 ResMgr::GetRemainSize()
return pFallbackResMgr->GetRemainSize();
const ImpRCStack& rTop = aStack[nCurStack];
return (sal_uInt32)((long)(sal_uInt8 *)rTop.pResource +
return (sal_uInt32)((sal_IntPtr)(sal_uInt8 *)rTop.pResource +
rTop.pResource->GetLocalOff() -
(long)(sal_uInt8 *)rTop.pClassRes);
(sal_IntPtr)(sal_uInt8 *)rTop.pClassRes);
}
void* ResMgr::Increment( sal_uInt32 nSize )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment