1. 25 Agu, 2015 28 kayıt (commit)
  2. 24 Agu, 2015 12 kayıt (commit)
    • Daniel Robertson's avatar
      slideshow: replace for_each with range-based loop · ead5bc3c
      Daniel Robertson yazdı
      Replace ::std::for_each for a more readable range-based for loop in
      cases in which the function object to be applied by for_each is more
      readable as the body of a for loop.
      
      Change-Id: Ib0b488b36ed58c65c56357e04391b85096d043aa
      Reviewed-on: https://gerrit.libreoffice.org/17930Tested-by: 's avatarJenkins <ci@libreoffice.org>
      Reviewed-by: 's avatarThorsten Behrens <Thorsten.Behrens@CIB.de>
      ead5bc3c
    • Caolán McNamara's avatar
      in reality we are limited to max sal_Int32 here · 0a76c1fd
      Caolán McNamara yazdı
      so accept that and test if the values were accepted or limited
      
      Change-Id: Iaed5ebc2f12b52055506147c71117a2ad88d28ac
      0a76c1fd
    • Caolán McNamara's avatar
      consider validity of m_nDrawCpO · 8329eb5e
      Caolán McNamara yazdı
      Change-Id: Ifbd131440bad6d840d369c99628cb8904697ad96
      8329eb5e
    • Stephan Bergmann's avatar
      Handle GetBaseCp overflow · d281b460
      Stephan Bergmann yazdı
      ...as found by UBSan in CppunitTest_sw_filters_test (see below); note the TODOs
      how best to report the errors up the call stack.
      
      > Testing file:///.../sw/qa/core/data/ww6/pass/crash-3.doc:
      > sw/source/filter/ww8/ww8scan.cxx:5240:63: runtime error: signed integer overflow: 1766665948 + 1768712052 cannot be represented in type 'int'
      >  WW8Fib::GetBaseCp(ManTypes) const sw/source/filter/ww8/ww8scan.cxx:5240:63
      >  SwWW8ImplReader::Read_GrafLayer(long) sw/source/filter/ww8/ww8graf.cxx:2393:18
      >  SwWW8ImplReader::ReadChar(long, long) sw/source/filter/ww8/ww8par.cxx:3630:17
      >  SwWW8ImplReader::ReadChars(int&, int, long, long) sw/source/filter/ww8/ww8par.cxx:3432:27
      >  SwWW8ImplReader::ReadText(int, int, ManTypes) sw/source/filter/ww8/ww8par.cxx:3970:22
      >  SwWW8ImplReader::CoreLoad(WW8Glossary*, SwPosition const&) sw/source/filter/ww8/ww8par.cxx:5169:9
      >  SwWW8ImplReader::LoadThroughDecryption(SwPaM&, WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:5767:19
      >  SwWW8ImplReader::LoadDoc(SwPaM&, WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:6039:19
      >  WW8Reader::Read(SwDoc&, rtl::OUString const&, SwPaM&, rtl::OUString const&) sw/source/filter/ww8/ww8par.cxx:6157:20
      >  SwReader::Read(Reader const&) sw/source/filter/basflt/shellio.cxx:175:18
      >  SwDocShell::ConvertFrom(SfxMedium&) sw/source/uibase/app/docsh.cxx:258:22
      >  SfxObjectShell::DoLoad(SfxMedium*) sfx2/source/doc/objstor.cxx:790:23
      >  SwFiltersTest::filter(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) sw/qa/core/filters-test.cxx:112:20
      >  SwFiltersTest::load(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int) sw/qa/core/filters-test.cxx:71:12
      >  test::FiltersTest::recursiveScan(test::filterStatus, rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) unotest/source/cpp/filters-test.cxx:129:20
      >  test::FiltersTest::testDir(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) unotest/source/cpp/filters-test.cxx:154:5
      >  SwFiltersTest::testCVEs() sw/qa/core/filters-test.cxx:154:5
      
      Change-Id: I0b14f5c1e025565eb131e64590b7d5ff0135e767
      Reviewed-on: https://gerrit.libreoffice.org/17965Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
      Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
      d281b460
    • Stephan Bergmann's avatar
      Handle zero nPLCF · 1a871f9d
      Stephan Bergmann yazdı
      ...as found by ASan in CppunitTest_sw_filters_test:
      
      > Testing file:///.../sw/qa/core/data/ww6/pass/crash-1.doc:
      > ERROR: AddressSanitizer: heap-buffer-overflow on address 0x6020009382b0 at pc 0x2b1dcb5eabac bp 0x7fffe8ccbdb0 sp 0x7fffe8ccbda8
      > READ of size 4 at 0x6020009382b0 thread T0
      >  WW8PLCF::SeekPos(int) sw/source/filter/ww8/ww8scan.cxx:2219:14
      >  WW8PLCF::WW8PLCF(SvStream&, int, int, int, int, int, int) sw/source/filter/ww8/ww8scan.cxx:2080:9
      >  WW8PLCFx_Fc_FKP::WW8PLCFx_Fc_FKP(SvStream*, SvStream*, SvStream*, WW8Fib const&, ePLCFT, int) sw/source/filter/ww8/ww8scan.cxx:2883:21
      >  WW8PLCFx_Cp_FKP::WW8PLCFx_Cp_FKP(SvStream*, SvStream*, SvStream*, WW8ScannerBase const&, ePLCFT) sw/source/filter/ww8/ww8scan.cxx:3088:7
      >  WW8ScannerBase::WW8ScannerBase(SvStream*, SvStream*, SvStream*, WW8Fib*) sw/source/filter/ww8/ww8scan.cxx:1588:20
      >  SwWW8ImplReader::CoreLoad(WW8Glossary*, SwPosition const&) sw/source/filter/ww8/ww8par.cxx:5022:20
      >  SwWW8ImplReader::LoadThroughDecryption(SwPaM&, WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:5767:19
      >  SwWW8ImplReader::LoadDoc(SwPaM&, WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:6039:19
      >  WW8Reader::Read(SwDoc&, rtl::OUString const&, SwPaM&, rtl::OUString const&) sw/source/filter/ww8/ww8par.cxx:6157:20
      >  SwReader::Read(Reader const&) sw/source/filter/basflt/shellio.cxx:175:18
      >  SwDocShell::ConvertFrom(SfxMedium&) sw/source/uibase/app/docsh.cxx:258:22
      >  SfxObjectShell::DoLoad(SfxMedium*) sfx2/source/doc/objstor.cxx:790:23
      >  SwFiltersTest::filter(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) sw/qa/core/filters-test.cxx:112:20
      >  SwFiltersTest::load(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int) sw/qa/core/filters-test.cxx:71:12
      >  test::FiltersTest::recursiveScan(test::filterStatus, rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) unotest/source/cpp/filters-test.cxx:129:20
      >  test::FiltersTest::testDir(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) unotest/source/cpp/filters-test.cxx:154:5
      >  SwFiltersTest::testCVEs() sw/qa/core/filters-test.cxx:154:5
      > 0x6020009382b1 is located 0 bytes to the right of 1-byte region [0x6020009382b0,0x6020009382b1)
      > allocated by thread T0 here:
      >  operator new[](unsigned long) /home/sbergman/clang/trunk/src/projects/compiler-rt/lib/asan/asan_new_delete.cc:64
      >  WW8PLCF::ReadPLCF(SvStream&, int, unsigned int) sw/source/filter/ww8/ww8scan.cxx:2091:26
      >  WW8PLCF::WW8PLCF(SvStream&, int, int, int, int, int, int) sw/source/filter/ww8/ww8scan.cxx:2075:9
      >  WW8PLCFx_Fc_FKP::WW8PLCFx_Fc_FKP(SvStream*, SvStream*, SvStream*, WW8Fib const&, ePLCFT, int) sw/source/filter/ww8/ww8scan.cxx:2883:21
      >  WW8PLCFx_Cp_FKP::WW8PLCFx_Cp_FKP(SvStream*, SvStream*, SvStream*, WW8ScannerBase const&, ePLCFT) sw/source/filter/ww8/ww8scan.cxx:3088:7
      >  WW8ScannerBase::WW8ScannerBase(SvStream*, SvStream*, SvStream*, WW8Fib*) sw/source/filter/ww8/ww8scan.cxx:1588:20
      >  SwWW8ImplReader::CoreLoad(WW8Glossary*, SwPosition const&) sw/source/filter/ww8/ww8par.cxx:5022:20
      >  SwWW8ImplReader::LoadThroughDecryption(SwPaM&, WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:5767:19
      >  SwWW8ImplReader::LoadDoc(SwPaM&, WW8Glossary*) sw/source/filter/ww8/ww8par.cxx:6039:19
      >  WW8Reader::Read(SwDoc&, rtl::OUString const&, SwPaM&, rtl::OUString const&) sw/source/filter/ww8/ww8par.cxx:6157:20
      >  SwReader::Read(Reader const&) sw/source/filter/basflt/shellio.cxx:175:18
      >  SwDocShell::ConvertFrom(SfxMedium&) sw/source/uibase/app/docsh.cxx:258:22
      >  SfxObjectShell::DoLoad(SfxMedium*) sfx2/source/doc/objstor.cxx:790:23
      >  SwFiltersTest::filter(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) sw/qa/core/filters-test.cxx:112:20
      >  SwFiltersTest::load(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int) sw/qa/core/filters-test.cxx:71:12
      >  test::FiltersTest::recursiveScan(test::filterStatus, rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) unotest/source/cpp/filters-test.cxx:129:20
      >  test::FiltersTest::testDir(rtl::OUString const&, rtl::OUString const&, rtl::OUString const&, SfxFilterFlags, SotClipboardFormatId, unsigned int, bool) unotest/source/cpp/filters-test.cxx:154:5
      >  SwFiltersTest::testCVEs() sw/qa/core/filters-test.cxx:154:5
      
      Change-Id: I97d995aad621b829b6fb6ee4622d386fec0bedea
      Reviewed-on: https://gerrit.libreoffice.org/17963Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
      Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
      1a871f9d
    • Tor Lillqvist's avatar
      Don't attempt to cache glyphs that are vertical but the text direction isn't · 32069752
      Tor Lillqvist yazdı
      That is a too complex and rare case to bother with, I think.
      
      Change-Id: Ica6ef7fa05314d2367dcff32627c1aec6ba8f8df
      32069752
    • Stephan Bergmann's avatar
      Clean up output · a4ef3f4e
      Stephan Bergmann yazdı
      Change-Id: I4fbcd03e4af82ba8e3697651ddce92ba0ba450a6
      a4ef3f4e
    • Stephan Bergmann's avatar
      Make test order deterministic · 82fb80ec
      Stephan Bergmann yazdı
      Change-Id: I9980034f0cb948acd6bb20aaf0fc27928ac68913
      82fb80ec
    • Caolán McNamara's avatar
      loop over successfully read bookmarks · 02e9b490
      Caolán McNamara yazdı
      not over the amount that should be there
      
      Change-Id: Ia2c353f9d7e274a5bebf405e1743ef1d1872b4de
      02e9b490
    • Caolán McNamara's avatar
      detect and reject loop in tif · 6b82437d
      Caolán McNamara yazdı
      Change-Id: I77d315fa432a3eb1a65539489a2ba6da8508b283
      6b82437d
    • Stephan Bergmann's avatar
      -Werror,-Wpessimizing-move ("moving a temporary object prevents copy elision") · 7e415c83
      Stephan Bergmann yazdı
      Change-Id: I9e5b74e5ff0348f0880972a82726178354ab7d0f
      7e415c83
    • Caolán McNamara's avatar
      allow avoiding config for CustomToolBarImportHelper · 48a047f2
      Caolán McNamara yazdı
      Change-Id: Iff0dd632f8c6b187d3515f542cc9fe2ca59088e5
      48a047f2