summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-03-06ofz#45286 Integer-overflowCaolán McNamara
Change-Id: I1fb3aa68fb4e2ad274053f30d04f20ea479e1f27 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131077 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-06ofz: Use-of-uninitialized-valueCaolán McNamara
Change-Id: I1f1771c384e88417f40ea9dd76378fb057e3d977 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131075 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-06ofz: Use-of-uninitialized-valueCaolán McNamara
Change-Id: I41554dec3819efcd8e28f82bb732141c85414e9f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131074 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-06cid#1502882 silence Unchecked dynamic_castCaolán McNamara
Change-Id: I30c2edd4df8175b9c5bbda91f6046d631193245d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131073 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-06clear UserCall in SdPage destructorNoel Grandin
because I want to ref-count SdrObject, which changes the lifecycles of these objects, and then if an SdPage dies before an SdrObject we have a dangling m_pUserCall pointer. Change-Id: Ia08178c1b2f288f6d9d489fb9fd79e67bc3ea61c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131065 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-06Fix tdf#147755 by copying the vector.Arnaud VERSINI
Revert partially 224953d896a3dba5d85992394525ab8b54d8c314 Change-Id: Ic12d3b0a080ad3af69fa5c4e8c9b4d331305a663 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131066 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-06crashtesting: assert that !rtl::isAscii in xmlError messageCaolán McNamara
probably detected since: commit 089ce740f9f97f9c7b13e37a31acfc94984e9a3e Date: Thu Feb 24 17:45:18 2022 +0300 Deduplicate rtl_*String_newConcat*L or similar Change-Id: I69ac57bd5718a4da85516e2a2afa79dc2b04665e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131068 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-06make CellTextAttr half the sizeLuboš Luňák
It's set for every cell with value. Change-Id: Ie46617a621e6eb16b5f67d92e85bf2155e650fb1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131072 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-06make a bunch of SvtBroadcaster/SvtListeners functions inlineLuboš Luňák
These classes are used extensively during some operations in Calc, and not even LTO can inline these when they end up in different binaries. Change-Id: I5b17a004c6cc039508b76d557d58714c83f237a5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131071 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-06os thrown -> is thrownCaolán McNamara
Change-Id: I114bb29c59ad9a4b20ca3f34b057b02d439fbd77 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131067 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-03-06link bug report to "likely wrong" commentJustin Luth
Change-Id: I3184037d3df79b1bf4c972046e7636b372662cdd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/129825 Tested-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
2022-03-06don't destroy and recreate broadcasters on large changes (tdf#131894)Luboš Luňák
Change-Id: If5377687e7bcfab00af37887d3aaf302fa615690 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131070 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-06do not destroy broadcasters and then recreate again (tdf#134268)Luboš Luňák
Sorting ends tells all listeners on all the sorted cells to end listening to stop updates, then sorts the cells and starts listening again. This will cause all broadcasters for the sorted cells to temporarily stop having any listeners, so they'll be deleted and removed from the mdds vector (which may additionally cause moving large parts of the mdds vector repeatedly). And since all listeners will want to listen again after the sort, this will all need to be reconstructed. To avoid this, temporarily block this removal and then later just checks and remove any possibly left-over broadcasters that ended up with no listeners. Change-Id: Ie2d41d9acd7b657cf31a445870ce7f18d28d5ebb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131069 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05remove a workaround that appears to be no longer necessaryLuboš Luňák
Presumably whatever the locking problem was, it's got fixed meanwhile. Change-Id: I7bbd6299a501396f53ed2e8ccaf7d5893744512b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131047 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05ofz#45167 Integer-overflowCaolán McNamara
Change-Id: Ib112686b192558421419a8695db9c3f35c5312da Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131058 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05compress RowHidden()/GetRowHeight() use in excel export (tdf#126326)Luboš Luňák
Change-Id: Idc6a704cfc820bbbb2b51eff8db8159c251ea9ab Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131062 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05Add checks to avoid finding empty substring / zero characterMike Kaganski
... which changed in commit 281989007fd7dea997ed9a65f513f80b1aff67dd Author Noel Grandin <noel@peralex.com> Date Tue Jul 01 13:17:01 2014 +0200 Use standard library optimised routines for OUString/OString for optimized cases: strchr/wcschr/strrchr/wcsrchr find trailing zero character, and strstr/wcsstr find empty string; previous/unoptimized code does not find these. This introduced inconsistency between char and sal_Unicode functions on non-Windows, and for sal_Unicode between Windows and non-Windows (because on Windows, optimized code is used for sal_Unicode, while on other platforms, unoptimized code is used). Change-Id: I68529c91b26f4113d9bd7777fc5ac4809349864b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131064 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-03-05don't bother tracking changes if both cells are empty (tdf#141174)Luboš Luňák
AppendContent() does something only if the cells differ, which can't be the case if they're both empty, so skip unallocated cells. Change-Id: I367801bac30a8ee641b4ce608392124bac6ef47a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131060 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05don't bother scanning nonexistent data (tdf#141182)Luboš Luňák
There's no point scanning for non-empty cells after the last data cell, and this avoids processing mdds structures (such as repeated creating of flat_segment_tree). Change-Id: Ibec324aa2de457e8439c38a561f55ced9f478899 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131059 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05tdf#136632: Use 'Save transparency' when exporting selected objects for PNGJulien Nabet
To avoid some regression, consider that transparency should be enabled by default. So only remove transparency if it's required explicitely. + change QA test since "Translucent" property isn't a bool but a sal_Int32 In officecfg/registry/schema/org/openoffice/Office/Common.xcs: <prop oor:name="Translucent" oor:type="xs:int" oor:nillable="false"> Change-Id: I9bfb6aae8e2e8a31dee82f73a9165989129f222a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131057 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-03-05GetComponentServiceName can be constNoel Grandin
Change-Id: Iac61eec0b27660dd2ff45f70c92de5a8cdc2c301 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131044 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-05ofz#45231 TimeoutCaolán McNamara
Change-Id: Id761d0aeaffe869c7ce3ea048bdee09b55ae60a9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131055 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05ofz: Use-of-uninitialized-valueCaolán McNamara
Change-Id: If75e11dc26aae51d658dddd464135dd8a4f965ce Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131054 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05add svm playback to local testingCaolán McNamara
Change-Id: Ie69f628ee3f37b5cdab206c0c1c201a94841bf03 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131053 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05ofz: Use-of-uninitialized-valueCaolán McNamara
Change-Id: I695b5721ec848845adff0a5c37b931b4cee5370d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131050 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05ofz#45233 need some more services to play back metafileCaolán McNamara
Change-Id: Iafda9d9ad919a4a1a80131962c50a4a24b4b9b83 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131049 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05ofz: record less than 10 bytes is invalidCaolán McNamara
Change-Id: Ie6b88efbc12b4c7fddb7459e50cba28fcbcf35fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131048 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-05Fix typosAndrea Gelmini
Change-Id: I87f35153bbf53f58d6c8ca7b14a7fd09fec4372f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131052 Tested-by: Jenkins Reviewed-by: Julien Nabet <serval2412@yahoo.fr>
2022-03-05tdf#38669 - Create the key event using a Unicode characterAndreas Heinisch
Instead of using a plain char, create a key event using a Unicode character, otherwise the key event creates texts including rectangles or wrong characters. Change-Id: I9ec0d64998927d54eb3ae90a192c3b28e235f56d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130721 Tested-by: Jenkins Reviewed-by: Andreas Heinisch <andreas.heinisch@yahoo.de>
2022-03-05AccessibleShape::GetStyle can be constNoel Grandin
Change-Id: Ic71ae0645c85ec27cc6a172d379070fe88a9f452 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131045 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-05make some svx methods constNoel Grandin
Change-Id: If04a160c46b8dbf641ca9d115d1560f17e87ce4d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131043 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
2022-03-05make sc_namedrangesobj test work with 16k columnsLuboš Luňák
'row1' is not a valid named range with 16k columns, it's a cell address. Since the named range is constructed by the test, not even 582fc887f1faafe8ff5f16a13a0208483a93353f can take care of it, so rename such ranges. Change-Id: I6643953d41e391c8c3cfc55768b06d61d9fcb0a2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131046 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05tdf#130924 replace debugging printf calls with SAL_INFO/SAL_WARNpragat-pandya
Change-Id: Iaef5eec6508d031ab711a71c0d8ecebb18112ef6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130764 Tested-by: Luboš Luňák <l.lunak@collabora.com> Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05remove more hardcoded sheet sizes from Calc testsLuboš Luňák
E.g. sctablesheetobj test had the limits hardcoded, even as actual numbers. Apparently some tests cannot easily access global settings, but this at least makes it easy to check all tests after modifying ScSheetLimits::CreateDefault(). Change-Id: I6cff577fb01b1ea262dcd1f9fde24e114e19abdc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131040 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05remove more hardcoded MAXROWLuboš Luňák
Change-Id: Ica57f18d3fd1bf9ec06f05869f4a956d7d1097b0 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131036 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05remove pAttrArray nullptr checksLuboš Luňák
I don't see how it possibly could be nullptr in a correct situation, ScColumn::Init() is called right after creating ScColumn. Also make a bunch of trivial forwarding functions inline. Change-Id: I710d3cd86a660a8b4dcfbb9966a685b657b93c18 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131035 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05introduce ScColumnData for ScColumn/ScTable code sharingLuboš Luňák
Since columns are allocated dynamically on demand, up until this commit ScTable had ScPatternAttr member for unallocated columns that it was using in place of those unallocated columns. But that meant either copy&pasting pieces of code from ScColumn, or having extra slightly more cumbersome shared function in ScColumn, or even nothing. Improve this by creating ScColumnData, which will be used as ScColumn base class to keep things working as before, but ScTable now also contains one ScColumnData instance and so it can also call its functions. Change-Id: If1d842c4a5aec32e2a7729358006d79cd831349f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131034 Tested-by: Jenkins Reviewed-by: Luboš Luňák <l.lunak@collabora.com>
2022-03-05Use rtl::isAsciiDigit instead of custom macroMike Kaganski
Change-Id: Iabca31825dd47cee661b47b14f09e96459a42015 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131033 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-03-05Convert some macros to local lambdasMike Kaganski
Change-Id: I22942588c7e7ebfb3f53cc5739d2bbd9a7ccfd41 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130983 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
2022-03-04ofz: Null-dereferenceCaolán McNamara
Change-Id: I01be4c06c6d97430953ada8f3f5f84ef0a389267 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131032 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04ofz: Null-dereferenceCaolán McNamara
Change-Id: I7d8e30dc85df3cc5800617e5b2f232136bb72cdd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131006 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500511 silence Resource leakCaolán McNamara
Change-Id: I37cdd52d965112598249b929fa49c759a88606c9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131002 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500524 Dereference after null checkCaolán McNamara
Change-Id: Ic76f1b4992f51bdfe10406734ce00135607db357 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131001 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500546 silence Explicit null dereferencedCaolán McNamara
Change-Id: I44b97965548bd84adf6dc3ec1c67f028a4b31075 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131000 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500566 Uninitialized scalar fieldCaolán McNamara
Change-Id: I63e81377227ab35a0697a1d90fb3c9302a12a2b5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130999 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500569 (likely) silence Explicit null dereferencedCaolán McNamara
Change-Id: Ib44b3dcb94998ce7bf28c9dc1cd3ca7acc6e5190 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130998 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500632 Using a moved objectCaolán McNamara
Change-Id: I5e7dd51c9f9b2b295ded161307bbe9a6a23c42de Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130997 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500637 Explicit null dereferencedCaolán McNamara
Change-Id: I813703287faff25a48aa695ccb9c43bf469354d4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130996 Tested-by: Caolán McNamara <caolanm@redhat.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500652 silence Explicit null dereferencedCaolán McNamara
Change-Id: Ifb96f7cf3d28b3bef70c8d920d8c926c76329fb8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130995 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
2022-03-04cid#1500666 Explicit null dereferencedCaolán McNamara
Change-Id: Id4283660feb95432995872b82e71c3331349f837 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130994 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>