[Libreoffice-commits] core.git: 4 commits - download.lst external/hunspell lingucomponent/source smoketest/smoketest.cxx svx/source tools/source

Caolán McNamara caolanm at redhat.com
Mon Apr 18 08:33:11 UTC 2016


 download.lst                                         |    2 -
 external/hunspell/StaticLibrary_hunspell.mk          |    1 
 external/hunspell/UnpackedTarball_hunspell.mk        |    1 
 external/hunspell/hunspell-iterator.patch.1          |   22 -------------------
 lingucomponent/source/spellcheck/spell/sspellimp.cxx |    1 
 smoketest/smoketest.cxx                              |    5 +++-
 svx/source/accessibility/ChildrenManagerImpl.cxx     |    7 ++----
 tools/source/generic/fract.cxx                       |    5 +++-
 8 files changed, 12 insertions(+), 32 deletions(-)

New commits:
commit 7405d9d15738ea2357f95ff6a0f864a17f3dc0e8
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Apr 17 21:28:20 2016 +0100

    reorg to silence coverity#1358586 Using invalid iterator
    
    Change-Id: If93cead2f4caa203b2d1a3e9c787625e6386dc3e

diff --git a/svx/source/accessibility/ChildrenManagerImpl.cxx b/svx/source/accessibility/ChildrenManagerImpl.cxx
index 35c11e4..5e5e6f3 100644
--- a/svx/source/accessibility/ChildrenManagerImpl.cxx
+++ b/svx/source/accessibility/ChildrenManagerImpl.cxx
@@ -367,17 +367,17 @@ void ChildrenManagerImpl::RemoveNonVisibleChildren (
     }
 }
 
-
 void ChildrenManagerImpl::MergeAccessibilityInformation (
     ChildDescriptorListType& raNewChildList)
 {
-    ChildDescriptorListType::iterator aOldChildDescriptor;
+    ChildDescriptorListType::const_iterator aStartVisibleChildren = maVisibleChildren.begin();
     ChildDescriptorListType::const_iterator aEndVisibleChildren = maVisibleChildren.end();
 
     ChildDescriptorListType::const_iterator aEnd = raNewChildList.end();
     for (ChildDescriptorListType::iterator I=raNewChildList.begin(); I != aEnd; ++I)
     {
-        aOldChildDescriptor = ::std::find (maVisibleChildren.begin(), maVisibleChildren.end(), *I);
+        ChildDescriptorListType::const_iterator aOldChildDescriptor =
+            std::find(aStartVisibleChildren, aEndVisibleChildren, *I);
 
         // Copy accessible shape if that exists in the old descriptor.
         bool bRegistrationIsNecessary = true;
@@ -393,7 +393,6 @@ void ChildrenManagerImpl::MergeAccessibilityInformation (
     }
 }
 
-
 void ChildrenManagerImpl::SendVisibleAreaEvents (
     ChildDescriptorListType& raNewChildList)
 {
commit 60c8704cf42ed24f3b8f3e698fd3072b82270af5
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Apr 17 21:31:38 2016 +0100

    coverity#1358589 Uninitialized scalar field
    
    Change-Id: I072dc4a54949fb3186be4a41e8865bdf0794297a

diff --git a/tools/source/generic/fract.cxx b/tools/source/generic/fract.cxx
index b6e8135..12530c7 100644
--- a/tools/source/generic/fract.cxx
+++ b/tools/source/generic/fract.cxx
@@ -42,7 +42,10 @@ struct Fraction::Impl
     bool                        valid;
     boost::rational<sal_Int64>  value;
 
-    Impl() = default;
+    Impl()
+        : valid(false)
+    {
+    }
     Impl(const Impl&) = delete;
     Impl& operator=(const Impl&) = delete;
 };
commit 5f78d62051d720552088895ac94fb02a06cf6e22
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sun Apr 17 21:29:57 2016 +0100

    coverity#1358588 Uninitialized scalar field
    
    Change-Id: I32596c33b9d8fc261d51c880ff1c049879f17509

diff --git a/smoketest/smoketest.cxx b/smoketest/smoketest.cxx
index fa301f7..2133cc1 100644
--- a/smoketest/smoketest.cxx
+++ b/smoketest/smoketest.cxx
@@ -59,7 +59,10 @@ struct Result {
     osl::Condition condition;
     bool success;
     OUString result;
-    Result() = default;
+    Result()
+        : success(false)
+    {
+    }
     Result(const Result&) = delete;
     Result& operator=(const Result&) = delete;
 };
commit 072b32442e3f6f220936a93ad1fcbde57746b747
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Sat Apr 16 15:05:55 2016 +0100

    try next hunspell 1.4.0 prerelease milestone
    
    try using reverse iterators here then
    
    and remove dictmgr which we don't seem to use or need
    
    Change-Id: I981fccc4ca7562d5ab707dc2f605e409169dec07

diff --git a/download.lst b/download.lst
index 19f727f..6512589 100644
--- a/download.lst
+++ b/download.lst
@@ -61,7 +61,7 @@ export GRAPHITE_TARBALL := 4311dd9ace498b57c85f611e0670df64-graphite2-minimal-1.
 export HARFBUZZ_MD5SUM := 0e27e531f4c4acff601ebff0957755c2
 export HARFBUZZ_TARBALL := harfbuzz-0.9.40.tar.bz2
 export HSQLDB_TARBALL := 17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip
-export HUNSPELL_TARBALL := 29de3467b11bde5a7743a93abeb8c0c8-hunspell-1.4.0.tar.gz
+export HUNSPELL_TARBALL := f95a5452e064fac41c85a70bba1728c5-hunspell-1.4.0.tar.gz
 export HYPHEN_TARBALL := 5ade6ae2a99bc1e9e57031ca88d36dad-hyphen-2.8.8.tar.gz
 export ICU_TARBALL := 976734806026a4ef8bdd17937c8898b9-icu4c-57_1-src.tgz
 export JFREEREPORT_FLOW_ENGINE_TARBALL := ba2930200c9f019c2d93a8c88c651a0f-flow-engine-0.9.4.zip
diff --git a/external/hunspell/StaticLibrary_hunspell.mk b/external/hunspell/StaticLibrary_hunspell.mk
index 29fe624..d69e5a5 100644
--- a/external/hunspell/StaticLibrary_hunspell.mk
+++ b/external/hunspell/StaticLibrary_hunspell.mk
@@ -23,7 +23,6 @@ $(eval $(call gb_StaticLibrary_add_defs,hunspell,\
 $(eval $(call gb_StaticLibrary_add_generated_cxxobjects,hunspell,\
 	UnpackedTarball/hunspell/src/hunspell/affentry \
 	UnpackedTarball/hunspell/src/hunspell/affixmgr \
-	UnpackedTarball/hunspell/src/hunspell/dictmgr \
 	UnpackedTarball/hunspell/src/hunspell/csutil \
 	UnpackedTarball/hunspell/src/hunspell/hashmgr \
 	UnpackedTarball/hunspell/src/hunspell/suggestmgr \
diff --git a/external/hunspell/UnpackedTarball_hunspell.mk b/external/hunspell/UnpackedTarball_hunspell.mk
index 3aae579..943e788 100644
--- a/external/hunspell/UnpackedTarball_hunspell.mk
+++ b/external/hunspell/UnpackedTarball_hunspell.mk
@@ -13,7 +13,6 @@ $(eval $(call gb_UnpackedTarball_set_tarball,hunspell,$(HUNSPELL_TARBALL)))
 
 $(eval $(call gb_UnpackedTarball_add_patches,hunspell,\
 	external/hunspell/hunspell-solaris.patch \
-	external/hunspell/hunspell-iterator.patch.1 \
 ))
 
 ifeq ($(COM),MSC)
diff --git a/external/hunspell/hunspell-iterator.patch.1 b/external/hunspell/hunspell-iterator.patch.1
deleted file mode 100644
index 046d6e0..0000000
--- a/external/hunspell/hunspell-iterator.patch.1
+++ /dev/null
@@ -1,22 +0,0 @@
-MSVC debug runtime iterators don't want to be decremented past begin()
-
---- hunspell/src/hunspell/affixmgr.cxx.orig	2016-04-15 23:30:37.555875079 +0200
-+++ hunspell/src/hunspell/affixmgr.cxx	2016-04-15 23:30:43.669875027 +0200
-@@ -4638,7 +4638,7 @@
-       return;
- 
-   int neg = 0;
--  for (std::string::iterator k = piece.begin() + piece.size() - 1; k >= piece.begin(); --k) {
-+  for (std::string::iterator k = piece.begin() + piece.size() - 1; ; --k) {
-     switch (*k) {
-       case '[': {
-         if (neg)
-@@ -4666,6 +4666,8 @@
-           *(k + 1) = *k;
-       }
-     }
-+    if (k == piece.begin())
-+        break;
-   }
- }
- 
diff --git a/lingucomponent/source/spellcheck/spell/sspellimp.cxx b/lingucomponent/source/spellcheck/spell/sspellimp.cxx
index 6979a33..a9a1575 100644
--- a/lingucomponent/source/spellcheck/spell/sspellimp.cxx
+++ b/lingucomponent/source/spellcheck/spell/sspellimp.cxx
@@ -31,7 +31,6 @@
 
 #include <lingutil.hxx>
 #include <hunspell.hxx>
-#include <dictmgr.hxx>
 #include <sspellimp.hxx>
 
 #include <linguistic/lngprops.hxx>


More information about the Libreoffice-commits mailing list