From d88b292704957818eff9a348a524b5c90b40031b Mon Sep 17 00:00:00 2001 From: Norbert Thiebaud Date: Sat, 16 Oct 2010 03:20:00 -0500 Subject: merge vosremoval-mutex.diff In practice the changeset is 'inspired' by vosremoval-mutex.diff but was essentially redone manually --- unotools/inc/unotools/accessiblerelationsethelper.hxx | 4 ++-- unotools/inc/unotools/accessiblestatesethelper.hxx | 4 ++-- unotools/inc/unotools/ucblockbytes.hxx | 12 ++++++------ .../source/accessibility/accessiblerelationsethelper.cxx | 14 +++++++------- .../source/accessibility/accessiblestatesethelper.cxx | 16 ++++++++-------- unotools/source/config/lingucfg.cxx | 2 +- unotools/source/config/misccfg.cxx | 2 +- unotools/source/config/undoopt.cxx | 2 +- unotools/source/config/useroptions.cxx | 2 +- unotools/source/ucbhelper/ucblockbytes.cxx | 12 ++++++------ 10 files changed, 35 insertions(+), 35 deletions(-) (limited to 'unotools') diff --git a/unotools/inc/unotools/accessiblerelationsethelper.hxx b/unotools/inc/unotools/accessiblerelationsethelper.hxx index edc05d1a54a7..7c20ed7a8281 100644 --- a/unotools/inc/unotools/accessiblerelationsethelper.hxx +++ b/unotools/inc/unotools/accessiblerelationsethelper.hxx @@ -37,7 +37,7 @@ #include #include #include -#include +#include #include #include @@ -147,7 +147,7 @@ public: protected: /// Mutex guarding this object. - ::vos::OMutex maMutex; + ::osl::Mutex maMutex; private: /// The implementation of this helper interface. diff --git a/unotools/inc/unotools/accessiblestatesethelper.hxx b/unotools/inc/unotools/accessiblestatesethelper.hxx index b7b830a4a247..5ef72a89f7eb 100644 --- a/unotools/inc/unotools/accessiblestatesethelper.hxx +++ b/unotools/inc/unotools/accessiblestatesethelper.hxx @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include @@ -169,7 +169,7 @@ public: protected: /// Mutex guarding this object. - ::vos::OMutex maMutex; + ::osl::Mutex maMutex; private: /// The implementation of this helper interface. diff --git a/unotools/inc/unotools/ucblockbytes.hxx b/unotools/inc/unotools/ucblockbytes.hxx index f06f9d9522e5..a7090d5efebc 100644 --- a/unotools/inc/unotools/ucblockbytes.hxx +++ b/unotools/inc/unotools/ucblockbytes.hxx @@ -36,7 +36,7 @@ #include #include -#include +#include #include #include #include @@ -107,7 +107,7 @@ class UNOTOOLS_DLLPUBLIC UcbLockBytes : public virtual SvLockBytes { osl::Condition m_aInitialized; osl::Condition m_aTerminated; - vos::OMutex m_aMutex; + osl::Mutex m_aMutex; String m_aContentType; String m_aRealURL; @@ -184,25 +184,25 @@ public: NS_UNO::Reference < NS_IO::XInputStream > getInputStream_Impl() const { - vos::OGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); + osl::MutexGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); return m_xInputStream; } NS_UNO::Reference < NS_IO::XOutputStream > getOutputStream_Impl() const { - vos::OGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); + osl::MutexGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); return m_xOutputStream; } NS_UNO::Reference < NS_IO::XSeekable > getSeekable_Impl() const { - vos::OGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); + osl::MutexGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); return m_xSeekable; } sal_Bool hasInputStream_Impl() const { - vos::OGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); + osl::MutexGuard aGuard( SAL_CONST_CAST(UcbLockBytes*, this)->m_aMutex ); return m_xInputStream.is(); } diff --git a/unotools/source/accessibility/accessiblerelationsethelper.cxx b/unotools/source/accessibility/accessiblerelationsethelper.cxx index 20fffdf7070f..55cfa3e6ef42 100644 --- a/unotools/source/accessibility/accessiblerelationsethelper.cxx +++ b/unotools/source/accessibility/accessiblerelationsethelper.cxx @@ -168,7 +168,7 @@ sal_Int32 SAL_CALL AccessibleRelationSetHelper::getRelationCount( ) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->getRelationCount(); } @@ -190,7 +190,7 @@ sal_Int32 SAL_CALL throw (lang::IndexOutOfBoundsException, uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->getRelation(nIndex); } @@ -210,7 +210,7 @@ sal_Bool SAL_CALL AccessibleRelationSetHelper::containsRelation( sal_Int16 aRelationType ) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->containsRelation(aRelationType); } @@ -229,14 +229,14 @@ AccessibleRelation SAL_CALL AccessibleRelationSetHelper::getRelationByType( sal_Int16 aRelationType ) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->getRelationByType(aRelationType); } void AccessibleRelationSetHelper::AddRelation(const AccessibleRelation& rRelation) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); mpHelperImpl->AddRelation(rRelation); } @@ -246,7 +246,7 @@ uno::Sequence< ::com::sun::star::uno::Type> AccessibleRelationSetHelper::getTypes (void) throw (::com::sun::star::uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); const ::com::sun::star::uno::Type aTypeList[] = { ::getCppuType((const uno::Reference< XAccessibleRelationSet>*)0), @@ -262,7 +262,7 @@ uno::Sequence SAL_CALL AccessibleRelationSetHelper::getImplementationId (void) throw (::com::sun::star::uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); static uno::Sequence aId; if (aId.getLength() == 0) { diff --git a/unotools/source/accessibility/accessiblestatesethelper.cxx b/unotools/source/accessibility/accessiblestatesethelper.cxx index 8927f3cfb6e0..d2f1e50960f6 100644 --- a/unotools/source/accessibility/accessiblestatesethelper.cxx +++ b/unotools/source/accessibility/accessiblestatesethelper.cxx @@ -207,7 +207,7 @@ AccessibleStateSetHelper::~AccessibleStateSetHelper(void) sal_Bool SAL_CALL AccessibleStateSetHelper::isEmpty () throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->IsEmpty(); } @@ -225,7 +225,7 @@ sal_Bool SAL_CALL AccessibleStateSetHelper::isEmpty () sal_Bool SAL_CALL AccessibleStateSetHelper::contains (sal_Int16 aState) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->Contains(aState); } @@ -248,7 +248,7 @@ sal_Bool SAL_CALL AccessibleStateSetHelper::containsAll (const uno::Sequence& rStateSet) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); sal_Int32 nCount(rStateSet.getLength()); const sal_Int16* pStates = rStateSet.getConstArray(); sal_Int32 i = 0; @@ -264,21 +264,21 @@ sal_Bool SAL_CALL AccessibleStateSetHelper::containsAll uno::Sequence SAL_CALL AccessibleStateSetHelper::getStates() throw (uno::RuntimeException) { - ::vos::OGuard aGuard(maMutex); + osl::MutexGuard aGuard(maMutex); return mpHelperImpl->GetStates(); } void AccessibleStateSetHelper::AddState(sal_Int16 aState) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); mpHelperImpl->AddState(aState); } void AccessibleStateSetHelper::RemoveState(sal_Int16 aState) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); mpHelperImpl->RemoveState(aState); } @@ -288,7 +288,7 @@ sal_Bool AccessibleStateSetHelper::Compare( AccessibleStateSetHelper& rNewStates) throw (uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); return mpHelperImpl->Compare(rComparativeValue.mpHelperImpl, rOldStates.mpHelperImpl, rNewStates.mpHelperImpl); } @@ -314,7 +314,7 @@ uno::Sequence SAL_CALL AccessibleStateSetHelper::getImplementationId (void) throw (::com::sun::star::uno::RuntimeException) { - ::vos::OGuard aGuard (maMutex); + osl::MutexGuard aGuard (maMutex); static uno::Sequence aId; if (aId.getLength() == 0) { diff --git a/unotools/source/config/lingucfg.cxx b/unotools/source/config/lingucfg.cxx index 5935cde25d1e..c11403f47a26 100644 --- a/unotools/source/config/lingucfg.cxx +++ b/unotools/source/config/lingucfg.cxx @@ -39,7 +39,7 @@ #include "com/sun/star/util/XMacroExpander.hpp" #include "com/sun/star/beans/XPropertySet.hpp" #include -#include +#include #include #include #include diff --git a/unotools/source/config/misccfg.cxx b/unotools/source/config/misccfg.cxx index 06db4a8da4ce..bb09c47fe887 100644 --- a/unotools/source/config/misccfg.cxx +++ b/unotools/source/config/misccfg.cxx @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include #include "itemholder1.hxx" diff --git a/unotools/source/config/undoopt.cxx b/unotools/source/config/undoopt.cxx index 7674a0ed05f7..f7e985c71318 100644 --- a/unotools/source/config/undoopt.cxx +++ b/unotools/source/config/undoopt.cxx @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include #include "itemholder1.hxx" diff --git a/unotools/source/config/useroptions.cxx b/unotools/source/config/useroptions.cxx index 01cdc1867904..57f23586e6e7 100644 --- a/unotools/source/config/useroptions.cxx +++ b/unotools/source/config/useroptions.cxx @@ -36,7 +36,7 @@ #include #include #include -#include +#include #include #include #include "itemholder1.hxx" diff --git a/unotools/source/ucbhelper/ucblockbytes.cxx b/unotools/source/ucbhelper/ucblockbytes.cxx index 0403eab0af31..272412d39fe2 100644 --- a/unotools/source/ucbhelper/ucblockbytes.cxx +++ b/unotools/source/ucbhelper/ucblockbytes.cxx @@ -29,6 +29,7 @@ // MARKER(update_precomp.py): autogen include statement, do not remove #include "precompiled_unotools.hxx" +#include #include #include #include @@ -1317,14 +1318,14 @@ UcbLockBytes::~UcbLockBytes() Reference < XInputStream > UcbLockBytes::getInputStream() { - vos::OClearableGuard aGuard( m_aMutex ); + osl::MutexGuard aGuard( m_aMutex ); m_bDontClose = sal_True; return m_xInputStream; } Reference < XStream > UcbLockBytes::getStream() { - vos::OClearableGuard aGuard( m_aMutex ); + osl::MutexGuard aGuard( m_aMutex ); Reference < XStream > xStream( m_xSeekable, UNO_QUERY ); if ( xStream.is() ) m_bDontClose = sal_True; @@ -1335,7 +1336,7 @@ Reference < XStream > UcbLockBytes::getStream() sal_Bool UcbLockBytes::setStream_Impl( const Reference& aStream ) { - vos::OClearableGuard aGuard( m_aMutex ); + osl::MutexGuard aGuard( m_aMutex ); if ( aStream.is() ) { m_xOutputStream = aStream->getOutputStream(); @@ -1357,7 +1358,7 @@ sal_Bool UcbLockBytes::setInputStream_Impl( const Reference &rxInp try { - vos::OClearableGuard aGuard( m_aMutex ); + osl::MutexGuard aGuard( m_aMutex ); if ( !m_bDontClose && m_xInputStream.is() ) m_xInputStream->closeInput(); @@ -1384,7 +1385,6 @@ sal_Bool UcbLockBytes::setInputStream_Impl( const Reference &rxInp } bRet = m_xInputStream.is(); - // aGuard.clear(); } catch( Exception& ) {} @@ -1466,7 +1466,7 @@ ErrCode UcbLockBytes::ReadAt ( ULONG nPos, void *pBuffer, ULONG nCount, ULONG *p Sequence aData; sal_Int32 nSize; - nCount = VOS_MIN(nCount, 0x7FFFFFFF); + nCount = SAL_MIN(nCount, 0x7FFFFFFF); try { if ( !m_bTerminated && !IsSynchronMode() ) -- cgit v1.2.3