From dbd675df91406b0542743fd86d0a0c732aba694a Mon Sep 17 00:00:00 2001 From: Fridrich Štrba Date: Tue, 4 Jun 2013 15:19:01 +0200 Subject: Some "cast from ... to ... loses precision fixes" Change-Id: Ib1d827bfa224e8708fd1e41b1ad213bcfef9a012 --- comphelper/source/misc/numberedcollection.cxx | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'comphelper/source') diff --git a/comphelper/source/misc/numberedcollection.cxx b/comphelper/source/misc/numberedcollection.cxx index f7f4d122c009..2f3e357f0167 100644 --- a/comphelper/source/misc/numberedcollection.cxx +++ b/comphelper/source/misc/numberedcollection.cxx @@ -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()) -- cgit