summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2019-07-19cid#1448351 Use after freeCaolán McNamara1-3/+3
Change-Id: I5591303096a495565e4e3638ca8db8196fa26092 Reviewed-on: https://gerrit.libreoffice.org/75913 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448451 Use after freeCaolán McNamara1-6/+5
Change-Id: I6df7a2d117be1c8f7a3e00387006c69857a98b1c Reviewed-on: https://gerrit.libreoffice.org/75914 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448547 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: If0b19a53bba10064a81a22856cd3796dcefd1f68 Reviewed-on: https://gerrit.libreoffice.org/75903 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448217 Use after freeCaolán McNamara3-6/+6
Change-Id: Icb7700c701dd8e9b23bfe29bbedf27ddd9c8f0a1 Reviewed-on: https://gerrit.libreoffice.org/75911 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19sw: fix use after free on tdf117215-1.odtMichael Stahl2-1/+3
Move the fix from 6d0ea082889c89eb8b408779f2de08da7441ff54 to SwFlyFrame::DestroyImpl() so we unregister every SwFlyFrame. ==1550==ERROR: AddressSanitizer: heap-use-after-free on address 0x615000383f56 at pc 0x7efcd70d5ab9 bp 0x7ffeb7ac7c40 sp 0x7ffeb7ac7c38 WRITE of size 1 at 0x615000383f56 thread T0 0 SwAnchoredObject::SetTmpConsiderWrapInfluence(bool) sw/source/core/layout/anchoredobject.cxx:743:32 1 SwObjsMarkedAsTmpConsiderWrapInfluence::Clear() sw/source/core/layout/objstmpconsiderwrapinfl.cxx:53:23 2 SwLayouter::ClearObjsTmpConsiderWrapInfluence(SwDoc const&) sw/source/core/layout/layouter.cxx:387:84 3 sw::DocumentLayoutManager::ClearSwLayouterEntries() sw/source/core/doc/DocumentLayoutManager.cxx:497:5 4 sw::DocumentStateManager::SetModified() sw/source/core/doc/DocumentStateManager.cxx:45:39 5 sw::DocumentContentOperationsManager::DeleteRangeImplImpl(SwPaM&) sw/source/core/doc/DocumentContentOperationsManager.cxx:3942:36 0x615000383f56 is located 342 bytes inside of 504-byte region [0x615000383e00,0x615000383ff8) freed by thread T0 here: 1 SwFlyAtContentFrame::~SwFlyAtContentFrame() sw/source/core/inc/flyfrms.hxx:159:7 2 SwFrame::DestroyFrame(SwFrame*) sw/source/core/layout/ssfrm.cxx:389:9 3 SwFrameFormat::DelFrames() sw/source/core/layout/atrfrm.cxx:2624:17 4 SwUndoFlyBase::DelFly(SwDoc*) sw/source/core/undo/undobj1.cxx:161:19 5 SwUndoDelLayFormat::SwUndoDelLayFormat(SwFrameFormat*) sw/source/core/undo/undobj1.cxx:403:5 6 SwHistoryTextFlyCnt::SwHistoryTextFlyCnt(SwFrameFormat*) sw/source/core/undo/rolbck.cxx:538:20 7 SwHistory::Add(SwFlyFrameFormat&, unsigned short&) sw/source/core/undo/rolbck.cxx:1083:50 8 SwUndoSaveContent::DelContentIndex(SwPosition const&, SwPosition const&, DelContentType) sw/source/core/undo/undobj.cxx:1020:39 9 SwUndoDelete::SwUndoDelete(SwPaM&, bool, bool) sw/source/core/undo/undel.cxx:229:9 11 sw::DocumentContentOperationsManager::DeleteRangeImplImpl(SwPaM&) sw/source/core/doc/DocumentContentOperationsManager.cxx:3939:55 Change-Id: Ia0c28c9d5792615cbb566e502374efd0f4056daf Reviewed-on: https://gerrit.libreoffice.org/75857 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de>
2019-07-19Fix typosAndrea Gelmini1-9/+9
Change-Id: I1b566ef38eaef3d6b20555e20b8353976fbdca5d Reviewed-on: https://gerrit.libreoffice.org/75927 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2019-07-19Fix typoAndrea Gelmini1-1/+1
Change-Id: Id35aaf69535385f99513acd80a2a1e4a4cdae861 Reviewed-on: https://gerrit.libreoffice.org/75928 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2019-07-19Fix typoAndrea Gelmini1-2/+2
Change-Id: I542d694bbab6ce8d07bee9345db70a64a2fc0963 Reviewed-on: https://gerrit.libreoffice.org/75924 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2019-07-19Fix typoAndrea Gelmini1-1/+1
Change-Id: I9840c48adae1f01f08e3dedebf93444aa49f8a97 Reviewed-on: https://gerrit.libreoffice.org/75929 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2019-07-19cid#1448480 Uncaught exceptionCaolán McNamara1-2/+2
Change-Id: Ied9ff9ea5d8b40c52e20c10f709836a193d5e940 Reviewed-on: https://gerrit.libreoffice.org/75896 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448489 Uncaught exceptionCaolán McNamara1-1/+1
Change-Id: Id0c55bdf3a51d21f4d0e9cc407dbff1db5eb55f4 Reviewed-on: https://gerrit.libreoffice.org/75899 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448488 Unchecked return valueCaolán McNamara1-2/+3
Change-Id: If42c4f2215057120774b4ad7e2755e4e861bd828 Reviewed-on: https://gerrit.libreoffice.org/75898 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448256 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: I13c95bdbfc3161cca3b136266c5fd2e57b34a093 Reviewed-on: https://gerrit.libreoffice.org/75870 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448455 Unchecked return valueCaolán McNamara1-2/+2
Change-Id: I4526fbd939934fc4233279d9839f72c781a588b5 Reviewed-on: https://gerrit.libreoffice.org/75894 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448495 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: I8a7f347d8f3ff6195b10e5559ff0682734c54eaf Reviewed-on: https://gerrit.libreoffice.org/75900 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448527 Unchecked return valueCaolán McNamara1-1/+3
Change-Id: I024b2cc088027cfb74dc009220e75e24b7228ea2 Reviewed-on: https://gerrit.libreoffice.org/75902 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448229 Division or modulo by zeroCaolán McNamara1-1/+6
Change-Id: I8d1d7415c82c7d48f8d4bdf7b86e397fce01c015 Reviewed-on: https://gerrit.libreoffice.org/75908 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448249 Identical code for different branchesCaolán McNamara1-1/+0
Change-Id: Ie34ff807eae5b058f2c234f42010931263859b35 Reviewed-on: https://gerrit.libreoffice.org/75906 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448399 Useless callCaolán McNamara1-2/+0
Change-Id: I5047aa583cbe2f96ea59434311463c91117a9266 Reviewed-on: https://gerrit.libreoffice.org/75907 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448509 Unchecked return value from libraryCaolán McNamara1-1/+1
Change-Id: Idda609ca8f1cad0e2a703b0b6ba3b0a2b661874b Reviewed-on: https://gerrit.libreoffice.org/75901 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1451641 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: Ifc9a6d3e268af27515cdf3b2b1da471368d50e87 Reviewed-on: https://gerrit.libreoffice.org/75904 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448429 Unchecked return valueCaolán McNamara1-7/+4
Change-Id: Iddbd6bc2126943752e2057b749fd6f9943261be7 Reviewed-on: https://gerrit.libreoffice.org/75888 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448295 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: I4b0dd4fc9051f04448a651cb87b449a58d2a5349 Reviewed-on: https://gerrit.libreoffice.org/75874 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448484 Unchecked return valueCaolán McNamara1-2/+2
Change-Id: I4e06228665c90820e88c72bfe4e462af9a0074e9 Reviewed-on: https://gerrit.libreoffice.org/75897 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448246 Result is not floating-pointCaolán McNamara1-1/+1
Change-Id: I96fb06ffec6f8196dfa01ff13d45c1f618e671fc Reviewed-on: https://gerrit.libreoffice.org/75905 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448319 Use after freeCaolán McNamara1-3/+4
Change-Id: I45a4ea5c21707606b8853bb775a7d9eec595b88c Reviewed-on: https://gerrit.libreoffice.org/75912 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448311 Dereference null return valueCaolán McNamara1-0/+2
Change-Id: Ie0ad350d48441dc6012dddc9fa3989acc4d4aab8 Reviewed-on: https://gerrit.libreoffice.org/75917 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448251 Unchecked dynamic_castCaolán McNamara1-5/+2
Change-Id: I96b87d05d6633849d7a32a40e87b9fb4ee48b15d Reviewed-on: https://gerrit.libreoffice.org/75916 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448358 Improper use of negative valueCaolán McNamara1-1/+1
Change-Id: Ife6a57484734cab759c31ca4ded688a03400e9b7 Reviewed-on: https://gerrit.libreoffice.org/75909 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#14561625 Unchecked dynamic_castCaolán McNamara1-4/+4
Change-Id: Ibe350b00633ae55434da6aafc5829682cead35af Reviewed-on: https://gerrit.libreoffice.org/75919 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1451638 Unchecked dynamic_castCaolán McNamara1-3/+3
Change-Id: Ia0fc1ffdd5dbed4b7c32587741d59dcf2782ed61 Reviewed-on: https://gerrit.libreoffice.org/75920 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448363 Unchecked dynamic_castCaolán McNamara1-1/+1
Change-Id: Ibfa31b291f58c90f052f1d052b6294e8c544965c Reviewed-on: https://gerrit.libreoffice.org/75918 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448293 Copy into fixed size bufferCaolán McNamara1-1/+2
Change-Id: I0ff36c58bf2448bdccc239582ba24b69c7431c6d Reviewed-on: https://gerrit.libreoffice.org/75921 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448215 RV: Bad use of return valueCaolán McNamara1-1/+1
Change-Id: Ie974436b9d639a676336a95d5fef6545869e1ca8 Reviewed-on: https://gerrit.libreoffice.org/75922 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#704863 Dereference after null checkCaolán McNamara1-2/+4
Change-Id: I472f48c64a6f2d13b124ede28a83dab3b46f759f Reviewed-on: https://gerrit.libreoffice.org/75915 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448308 Unintended sign extensionCaolán McNamara1-26/+26
Change-Id: I3d89afa66dc42144f0717c34593d48c4869aeec4 Reviewed-on: https://gerrit.libreoffice.org/75923 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19tdf#42949 Fix IWYU warnings in include/dbaccessGabor Kelemen5-17/+1
Found with bin/find-unneeded-includes Only removal proposals are dealt with here. Change-Id: Ie537e44054c0d1735f42e74385cc1bd8c8000c16 Reviewed-on: https://gerrit.libreoffice.org/75180 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-07-19sw btlr writing mode: remove not needed checkFrameBtlr() in the DOCX exportMiklos Vajna3-71/+2
Now that the DOCX import doesn't create this and instead uses the proper writing mode (neither VML nor drawingmL). Change-Id: I560c710866de8fb2f90d681e8cfc2d82afb1a327 Reviewed-on: https://gerrit.libreoffice.org/75930 Tested-by: Jenkins Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-07-19make cppunitassertequals a shared pluginNoel Grandin2-5/+28
Change-Id: Ied9c26248cb72f2146fbe1a985f825f7525fa17c Reviewed-on: https://gerrit.libreoffice.org/75836 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-07-19coverity concurrency annotation attemptNoel Grandin1-0/+20
Let us see what happens if we annotate our mutex code, https://scan.coverity.com/models Change-Id: I7baf44d1a252f19b4ae47f3a6b318f7ccd9629d7 Reviewed-on: https://gerrit.libreoffice.org/75851 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-07-19loplugin:constantparamNoel Grandin24-1688/+1513
and tweak the plugin to handle a crash seen with clang-9 Change-Id: Ie1ccf80c16a20dbca58e5bd081af13f75cf5ac8f Reviewed-on: https://gerrit.libreoffice.org/75850 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2019-07-19NB fix context- behaviour in draw and impressandreas kainz3-17/+3
Change-Id: I943466895a51463be59dacb3686926d29562a371 Reviewed-on: https://gerrit.libreoffice.org/75931 Tested-by: Jenkins Reviewed-by: andreas_kainz <kainz.a@gmail.com>
2019-07-19tdf#125609 toolkit: don't use XTabController::getControlsJustin Luth1-8/+7
Calling XTabController::getControls was supposed to give performance improvements (coded in OOo), but it pulls cached information which is not up to date if this listener for elementInserted events is handled before the formController's listener. It is missing the most recently created control - and thus it never sees the last control in the form, and fails to create the radio group. Additionally, when all of the controls are not yet created, this function seems to be designed to catch that and immediately return. With the "optimization" the missing controls were never noticed, and so unnecessary processing continued - a performance detriment while the form is being built. My impresssion is that the local getControl() function is not terribly inefficient, so the performance impact seems minimal, especially since it now only makes the call once and caches the result itself. Since not-yet-peered controls cause the function to again terminate early (as it was designed to do), this may have unintended side effects, in case anything was designed in the past 10+ years expecting the old behaviour, so I have no intention of back-porting this. Change-Id: Ica8ddab69043a30b23d008cd8db5df1c13b94ad2 Reviewed-on: https://gerrit.libreoffice.org/75163 Tested-by: Jenkins Reviewed-by: Justin Luth <justin_luth@sil.org>
2019-07-19sw: fix missing OLE preview for actively edited OLE object on saveMiklos Vajna3-0/+44
Regression from commit 74844277cc2194c9e43f5bd7a6f78a9603da32f3 (disable generation of ole previews in ODF format until after load, 2016-09-13), if the user started an OLE edit in a Writer document, and saved without ending the OLE edit, then svt::EmbeddedObjectRef::UpdateReplacementOnDemand() removed the old replacement image, but no new one was created. Given that save is always an explicit user action (auto-save does not kick in for unmodified documents), restore the permission to update OLE replacement images during save. Do this check in SwDocShell::CalcLayoutForOLEObjects(), as that's OLE-related and is called from all the relevant save code paths (save, save-as, convert to alien formats). Change-Id: Idaad43909cd744a379e713efd70ffd000e2692bc Reviewed-on: https://gerrit.libreoffice.org/75867 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
2019-07-19cid#1448438 Uncaught exceptionCaolán McNamara1-1/+1
Change-Id: I444e8c8833db6bb0af9cfc7c3b18b45178faa663 Reviewed-on: https://gerrit.libreoffice.org/75892 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448441 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: I97f6ad2bd0a6d838871cfb9ff54f2e654d6abfd0 Reviewed-on: https://gerrit.libreoffice.org/75893 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448426 Unchecked return valueCaolán McNamara1-1/+1
Change-Id: Ia6ad812f76d1f69eb91a7d4f65f221b6598ce05a Reviewed-on: https://gerrit.libreoffice.org/75887 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448435 Unchecked return valueCaolán McNamara1-4/+6
Change-Id: I1c75280dfcfa1f475d657570bf390847ab922cc8 Reviewed-on: https://gerrit.libreoffice.org/75889 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448436 Unchecked return valueCaolán McNamara1-3/+6
Change-Id: I971587c6340afc83ac3a28b148650a8f20120164 Reviewed-on: https://gerrit.libreoffice.org/75890 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
2019-07-19cid#1448437 Unchecked return valueCaolán McNamara1-2/+2
Change-Id: I2dec7a66f5609b1e34d9b337f8c562440d3f5132 Reviewed-on: https://gerrit.libreoffice.org/75891 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>