[Libreoffice-commits] core.git: 5 commits - external/nss include/sal sw/source

Michael Stahl mstahl at redhat.com
Thu Feb 25 11:39:06 UTC 2016


 external/nss/README                    |   64 ++-------------------------------
 include/sal/log-areas.dox              |    1 
 sw/source/core/access/acccell.cxx      |    2 -
 sw/source/core/access/acccontext.cxx   |    8 ++--
 sw/source/core/access/accframe.hxx     |    2 -
 sw/source/core/access/accmap.cxx       |    2 -
 sw/source/core/access/accpara.cxx      |   22 ++++++++++-
 sw/source/core/access/acctable.cxx     |    4 +-
 sw/source/core/access/acctextframe.cxx |    8 ++--
 sw/source/core/frmedt/feshview.cxx     |    5 +-
 10 files changed, 42 insertions(+), 76 deletions(-)

New commits:
commit aef004cea8e7b93f84c13292a009e689f99383d8
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Feb 24 14:11:39 2016 +0100

    nss: remove obvious cruft from README
    
    Change-Id: If99babda104a35563208e89d86bf10bcff8f22f4

diff --git a/external/nss/README b/external/nss/README
index 0c5adf8..d4fbd68 100644
--- a/external/nss/README
+++ b/external/nss/README
@@ -1,32 +1,9 @@
-Contains the security libraries which are also part of [[moz]]. However nss is meant to be more current.
-
-== Relation between nss, moz, moz_prebuilt ==
-
-nss contains the security libraries which are also part of moz. However nss is
-meant to be more current, that is it to be updated more often. This should be
-easier than doing this with moz.
-
-If nss is built depends on an environment variable (SYSTEM_NSS=NO) which
-is per default set to YES. In this case nss is build before moz. The nss
-libraries/lib files/headers built in moz are then not delivered. Otherwise they
-would overwrite those from nss. That is, the nss libraries build in moz are
-removed from mozruntime.zip (build in moz/solver/bin), they are removed from the
-lib directory (for example moz/unxlngi6.pro/lib), and the nss and nspr headers
-are also removed (inc/nss and inc/nspr).  The nss libraries from the nss module
-are then added to mozruntime.zip.
-
-This also applies for moz_prebuilt. Therefore moz and moz_prebuilt must be build
-again after changes have been made to the libraries in the nss module.
-
-Also when moz was updated to use a newer version of mozilla, then one must make
-sure that new files which also belong to nss are not delivered and are removed
-from mozruntime.zip.
-
+Contains the Network Security Services (NSS) libraries from Mozilla
 
 == Fips 140 and signed libraries ==
 
 Fips 140 mode is not supported. That is, the *.chk files containing the
-checksums for the cryptographic module are not delivered into solver and will
+checksums for the cryptographic module are not delivered into instdir and will
 not be part of the OOo installation sets.
 
 Signing has been turned off because
@@ -34,48 +11,15 @@ Signing has been turned off because
 (Mac)
 - sqlite conflicts with the system sqlite when signing which breaks the build
 
-
-== libfreebl3 ==
-
-Porting to other platforms may require to deliver other variants of
-libfreebl*. The library name varies according to the platform. Changes need to
-be made to
-ooo/moz/extractfiles.mk
-ooo/moz/zipped/makefile.mk
-sun/moz_prebuilt/zipped/makefile.mk
-
 See also
-[http://www.mozilla.org/projects/security/pki/nss/tech-notes/tn6.html]
-
-
-== Windows builds of nss ==
-
-To build mozilla on windows you'll need the mozilla build tools
-
-Build requirements containing the link to the build tools:
-[https://developer.mozilla.org/en/Windows_Build_Prerequisites#ss2.2]
-
-The direct link:
-[http://ftp.mozilla.org/pub/mozilla.org/mozilla/libraries/win32/MozillaBuildSetup-1.3.exe]
-
+[https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/NSS_Tech_Notes/nss_tech_note6]
 
 == libsqlite3 ==
 
-The system sqlite in Mac OS X versions older than 10.6 is incompatible
-with the softokn3 in nss which requires a later version of sqlite.
-With SDK 10.6 (and more current SDK) we use
+With all supported Mac OS X SDK we use
 NSS_USE_SYSTEM_SQLITE=1
 to build using the system sqlite.
 
-The problem described here was found on Mac with OS 10.6
-We cannot deliver sqlite in the lib directory of the solver. This directory is
-used by tools of the build environment. Using the sqlite from NSS breaks the
-tools if they use system libraries which are linked with the system
-sqlite. Therefore we deliver it into lib/sqlite on unix systems.
-
-See also issue:
-[https://bz.apache.org/ooo/show_bug.cgi?id=106132]
-
 == system NSS on Linux ==
 
 Note that different Linux distributions use different SONAMEs for the
commit ca19248b24abcd8e7d032ea99196fecc96b67744
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Feb 24 23:38:48 2016 +0100

    sw: some missing locks in SwAccessibleParagraph
    
    Change-Id: I9eb8eed31702f6386b262a182fc36557e9cd8e8c

diff --git a/sw/source/core/access/accpara.cxx b/sw/source/core/access/accpara.cxx
index e6b3b0a..3f96b4b 100644
--- a/sw/source/core/access/accpara.cxx
+++ b/sw/source/core/access/accpara.cxx
@@ -1070,6 +1070,8 @@ static bool lcl_GetBackgroundColor( Color & rColor,
 sal_Int32 SAL_CALL SwAccessibleParagraph::getForeground()
                                 throw (uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     Color aBackgroundCol;
 
     if ( lcl_GetBackgroundColor( aBackgroundCol, GetFrame(), GetCursorShell() ) )
@@ -1090,6 +1092,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getForeground()
 sal_Int32 SAL_CALL SwAccessibleParagraph::getBackground()
                                 throw (uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     Color aBackgroundCol;
 
     if ( lcl_GetBackgroundColor( aBackgroundCol, GetFrame(), GetCursorShell() ) )
@@ -3248,6 +3252,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getTextMarkupCount( sal_Int32 nTextMar
                                         throw (lang::IllegalArgumentException,
                                                uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     std::unique_ptr<SwTextMarkupHelper> pTextMarkupHelper;
     switch ( nTextMarkupType )
     {
@@ -3473,6 +3479,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::addSelection( sal_Int32, sal_Int32 sta
                                                lang::IllegalArgumentException,
                                                uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     std::unique_ptr<SwTextMarkupHelper> pTextMarkupHelper;
     switch ( nTextMarkupType )
     {
@@ -3501,6 +3509,8 @@ uno::Sequence< /*accessibility::*/TextSegment > SAL_CALL
                                                lang::IllegalArgumentException,
                                                uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     // parameter checking
     const sal_Int32 nLength = GetString().getLength();
     if ( ! IsValidPosition( nCharIndex, nLength ) )
@@ -3534,6 +3544,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getLineNumberAtIndex( sal_Int32 nIndex
                                         throw (lang::IndexOutOfBoundsException,
                                                uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     // parameter checking
     const sal_Int32 nLength = GetString().getLength();
     if ( ! IsValidPosition( nIndex, nLength ) )
@@ -3550,6 +3562,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getLineNumberAtIndex( sal_Int32 nIndex
                                         throw (lang::IndexOutOfBoundsException,
                                                uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     // parameter checking
     if ( nLineNo < 0 ||
          nLineNo >= GetPortionData().GetLineCount() )
@@ -3573,6 +3587,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getLineNumberAtIndex( sal_Int32 nIndex
 /*accessibility::*/TextSegment SAL_CALL SwAccessibleParagraph::getTextAtLineWithCaret()
                                         throw (uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     const sal_Int32 nLineNoOfCaret = getNumberOfLineWithCaret();
 
     if ( nLineNoOfCaret >= 0 &&
@@ -3587,6 +3603,8 @@ sal_Int32 SAL_CALL SwAccessibleParagraph::getLineNumberAtIndex( sal_Int32 nIndex
 sal_Int32 SAL_CALL SwAccessibleParagraph::getNumberOfLineWithCaret()
                                         throw (uno::RuntimeException, std::exception)
 {
+    SolarMutexGuard g;
+
     const sal_Int32 nCaretPos = getCaretPosition();
     const sal_Int32 nLength = GetString().getLength();
     if ( !IsValidPosition( nCaretPos, nLength ) )
commit 015b2cce565b335dfb644ea1dfe44dede8d60815
Author: Michael Stahl <mstahl at redhat.com>
Date:   Wed Feb 24 23:33:18 2016 +0100

    sw: avoid creating SwAccessibles for 0-sized layout frames
    
    During layout it happens that a page is deleted and therefore
    the footer of the next page moves upward by a pagesize, so a
    CHILD_POS_CHANGED accessibility event is generated.
    
    The footer still has 0 size (and 0 position) at that point, so
    it's highly questionable that anybody would be interested in
    seeing such events.
    
    The event causes a SwAcessible to be created, but for the
    parent SwPageFrame no SwAccessible has been created, so the
    recursive dispose in ~SwAccessibleMap will leave these
    still in the mpFrameMap, as they happen to be invisible then,
    and only visible children of SwPageFrames are disposed,
    so that's a bit unlucky.
    
    Unfortunately this can't explain the crash in tdf#58624
    because there is actually code in ~SwAccessibleMap to clear
    the m_pMap back-pointer in all entries of mpFrameMap.
    
    Change-Id: Ic75254310af1bf8eca382c3745c4fe31c6b6f4a0

diff --git a/sw/source/core/access/acccontext.cxx b/sw/source/core/access/acccontext.cxx
index e200104..0e42527 100644
--- a/sw/source/core/access/acccontext.cxx
+++ b/sw/source/core/access/acccontext.cxx
@@ -1149,9 +1149,11 @@ void SwAccessibleContext::InvalidateChildPosOrSize(
 {
     SolarMutexGuard aGuard;
 
-    OSL_ENSURE( !rChildFrameOrObj.GetSwFrame() ||
-            !rChildFrameOrObj.GetSwFrame()->Frame().IsEmpty(),
-            "child context should have a size" );
+    // this happens during layout, e.g. when a page is deleted and next page's
+    // header/footer moves backward such an event is generated
+    SAL_INFO_IF(rChildFrameOrObj.GetSwFrame() &&
+            rChildFrameOrObj.GetSwFrame()->Frame().IsEmpty(),
+            "sw.a11y", "child context should have a size");
 
     if ( rChildFrameOrObj.AlwaysIncludeAsChild() )
     {
diff --git a/sw/source/core/access/accframe.hxx b/sw/source/core/access/accframe.hxx
index 55d9e24..f128bee 100644
--- a/sw/source/core/access/accframe.hxx
+++ b/sw/source/core/access/accframe.hxx
@@ -148,7 +148,7 @@ protected:
 
 inline bool SwAccessibleFrame::IsShowing( const SwRect& rFrame ) const
 {
-    return rFrame.IsOver( maVisArea );
+    return !rFrame.IsEmpty() && rFrame.IsOver( maVisArea );
 }
 
 inline bool SwAccessibleFrame::IsShowing( const SwAccessibleMap& rAccMap ) const
commit 789bfa540f8e01606f5d6c2defe04fbba3217432
Author: Michael Stahl <mstahl at redhat.com>
Date:   Tue Feb 23 23:01:36 2016 +0100

    sw: fix assert in SwAccessibleFrameBase::GetStates()
    
    We get this assert(bIsSelected && "bSelected out of sync");
    when double clicking on frames in the navigator.
    
    Reason is that SwCursorShell::UpdateCursor() calls MakeSelVisible()
    to scroll to it before calling InvalidateAccessibleCursorPosition().
    
    Scrolling causes loads of CHILD a11y events and the ATK backend
    registers event handlers everywhere and calls GetStates(),
    which sees that its frame is selected in the shell but its own
    bIsSelected flag wasn't set yet.
    
    Change-Id: Id69c9de2591a5d2d10d181c2ab2339daf97fe488

diff --git a/sw/source/core/frmedt/feshview.cxx b/sw/source/core/frmedt/feshview.cxx
index 8de3667..c599111 100644
--- a/sw/source/core/frmedt/feshview.cxx
+++ b/sw/source/core/frmedt/feshview.cxx
@@ -2290,9 +2290,10 @@ bool SwFEShell::GotoFly( const OUString& rName, FlyCntType eType, bool bSelFrame
         {
             if( bSelFrame )
             {
-                SelectObj( pFrame->Frame().Pos(), 0, pFrame->GetVirtDrawObj() );
-                if( !ActionPend() )
+                // first make visible, to get a11y events in proper order
+                if (!ActionPend())
                     MakeVisible( pFrame->Frame() );
+                SelectObj( pFrame->Frame().Pos(), 0, pFrame->GetVirtDrawObj() );
             }
             else
             {
commit 46251758a325c4edfdd9efcedc5d321ee6e5c0c5
Author: Michael Stahl <mstahl at redhat.com>
Date:   Tue Feb 23 22:32:02 2016 +0100

    sw: new sw.a11y log area
    
    Change-Id: I43b6b60ac91c7934d4045b8df618dc6592c0e688

diff --git a/include/sal/log-areas.dox b/include/sal/log-areas.dox
index b83eba7..d2de637 100644
--- a/include/sal/log-areas.dox
+++ b/include/sal/log-areas.dox
@@ -448,6 +448,7 @@ certain functionality.
 
 @li @c sw
 @li @c sw.core - Writer core
+ at li @c sw.a11y - accessibility
 @li @c sw.createcopy
 @li @c sw.doc
 @li @c sw.docappend
diff --git a/sw/source/core/access/acccell.cxx b/sw/source/core/access/acccell.cxx
index 64315c2..31296fd 100644
--- a/sw/source/core/access/acccell.cxx
+++ b/sw/source/core/access/acccell.cxx
@@ -118,7 +118,7 @@ SwAccessibleCell::SwAccessibleCell( SwAccessibleMap *pInitMap,
     SAL_WARN_IF(
         (!xContextTable.is()
          || xContextTable->getAccessibleRole() != AccessibleRole::TABLE),
-        "sw.core", "bad accessible context");
+        "sw.a11y", "bad accessible context");
     m_pAccTable = static_cast<SwAccessibleTable *>(xTableReference.get());
 }
 
diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx
index f7de950..7ea16d4 100644
--- a/sw/source/core/access/accmap.cxx
+++ b/sw/source/core/access/accmap.cxx
@@ -192,7 +192,7 @@ void SwDrawModellListener_Impl::Notify( SfxBroadcaster& /*rBC*/,
         }
         catch( uno::RuntimeException const & r )
         {
-            SAL_WARN( "sw.core", "Runtime exception caught while notifying shape.: " << r.Message );
+            SAL_WARN("sw.a11y", "Runtime exception caught while notifying shape: " << r.Message);
         }
     }
 }
diff --git a/sw/source/core/access/accpara.cxx b/sw/source/core/access/accpara.cxx
index 6294a62..e6b3b0a 100644
--- a/sw/source/core/access/accpara.cxx
+++ b/sw/source/core/access/accpara.cxx
@@ -3708,7 +3708,7 @@ bool SwAccessibleParagraph::GetSelectionAtIndex(
                                 SAL_WARN_IF(
                                     GetPortionData().IsValidCorePosition(
                                                                   nCoreStart),
-                                    "sw.core",
+                                    "sw.a11y",
                                     "problem determining valid core position");
 
                                 nLocalStart =
@@ -3747,7 +3747,7 @@ bool SwAccessibleParagraph::GetSelectionAtIndex(
                                 SAL_WARN_IF(
                                     GetPortionData().IsValidCorePosition(
                                                                   nCoreEnd),
-                                    "sw.core",
+                                    "sw.a11y",
                                     "problem determining valid core position");
 
                                 nLocalEnd = GetPortionData().GetAccessiblePosition(
diff --git a/sw/source/core/access/acctable.cxx b/sw/source/core/access/acctable.cxx
index 04541c8..5ced1de 100644
--- a/sw/source/core/access/acctable.cxx
+++ b/sw/source/core/access/acctable.cxx
@@ -1434,8 +1434,8 @@ void SwAccessibleTable::InvalidateChildPosOrSize( const SwAccessibleChild& rChil
     if( HasTableData() )
     {
         SAL_WARN_IF( HasTableData() &&
-                GetFrame()->Frame().Pos() != GetTableData().GetTablePos(), "sw.core",
-                "table has invalid position" );
+                GetFrame()->Frame().Pos() != GetTableData().GetTablePos(),
+                "sw.a11y", "table has invalid position" );
         if( HasTableData() )
         {
             SwAccessibleTableData_Impl *pNewTableData = CreateNewTableData(); // #i77106#
diff --git a/sw/source/core/access/acctextframe.cxx b/sw/source/core/access/acctextframe.cxx
index ac33818..aa78c4f 100644
--- a/sw/source/core/access/acctextframe.cxx
+++ b/sw/source/core/access/acctextframe.cxx
@@ -172,7 +172,7 @@ void SAL_CALL
 void SAL_CALL SwAccessibleTextFrame::selectAccessibleChild( sal_Int32 )
     throw ( lang::IndexOutOfBoundsException, uno::RuntimeException, std::exception )
 {
-    SAL_WARN("sw.core", "<SwAccessibleTextFrame::selectAccessibleChild( sal_Int32 )> - missing implementation" );
+    SAL_WARN("sw.a11y", "<SwAccessibleTextFrame::selectAccessibleChild( sal_Int32 )> - missing implementation");
 }
 
 sal_Bool SAL_CALL SwAccessibleTextFrame::isAccessibleChildSelected( sal_Int32 nChildIndex )
@@ -204,13 +204,13 @@ sal_Bool SAL_CALL SwAccessibleTextFrame::isAccessibleChildSelected( sal_Int32 nC
 void SAL_CALL SwAccessibleTextFrame::clearAccessibleSelection(  )
     throw ( uno::RuntimeException, std::exception )
 {
-    SAL_WARN("sw.core", "<SwAccessibleTextFrame::clearAccessibleSelection(  )> - missing implementation");
+    SAL_WARN("sw.a11y", "<SwAccessibleTextFrame::clearAccessibleSelection()> - missing implementation");
 }
 
 void SAL_CALL SwAccessibleTextFrame::selectAllAccessibleChildren(  )
     throw ( uno::RuntimeException, std::exception )
 {
-    SAL_WARN("sw.core", "<SwAccessibleTextFrame::selectAllAccessibleChildren(  )> - missing implementation");
+    SAL_WARN("sw.a11y", "<SwAccessibleTextFrame::selectAllAccessibleChildren()> - missing implementation");
 }
 
 sal_Int32 SAL_CALL SwAccessibleTextFrame::getSelectedAccessibleChildCount()
@@ -245,7 +245,7 @@ uno::Reference<XAccessible> SAL_CALL SwAccessibleTextFrame::getSelectedAccessibl
 void SAL_CALL SwAccessibleTextFrame::deselectAccessibleChild( sal_Int32 )
     throw ( lang::IndexOutOfBoundsException, uno::RuntimeException, std::exception )
 {
-    SAL_WARN("sw.core", "<SwAccessibleTextFrame::selectAllAccessibleChildren( sal_Int32 )> - missing implementation");
+    SAL_WARN("sw.a11y", "<SwAccessibleTextFrame::selectAllAccessibleChildren( sal_Int32 )> - missing implementation");
 }
 
 // #i73249#


More information about the Libreoffice-commits mailing list