summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2020-04-21tdf#127711 - A runtime-switch for the MiniCrashDump and associated changesJuergen Funk24-138/+283
- add CrashDumpEnable to soffice.ini - also check env var CRASH_DUMP_ENABLE (overrides soffice.ini) - make sure _all_ binaries are added to symstore This is a squash of: https://gerrit.libreoffice.org/79273 https://gerrit.libreoffice.org/81989 https://gerrit.libreoffice.org/c/core/+/87260 https://gerrit.libreoffice.org/c/core/+/87261 https://gerrit.libreoffice.org/79272 https://gerrit.libreoffice.org/83171 https://gerrit.libreoffice.org/82751 https://gerrit.libreoffice.org/83066 https://gerrit.libreoffice.org/83726 https://gerrit.libreoffice.org/c/core/+/86465
2020-04-08Related tdf#97694 Fix macro preservation on WindowsSamuel Mehrbrodt1-3/+6
Change-Id: Ief183c75e0c3ce6c42868b7c60c5f66f9684d743 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91795 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 792c730f3cda4f5c312921a62ecae3d322ad9b72) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91920 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-04-08Related tdf#97694 Preserve macro signatures in BaseSamuel Mehrbrodt1-1/+90
Change-Id: I139ac003d1c95144e6cb1beec774f3cf142625b7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91466 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 8d27d495a733cfc29753e2e78000b199632695f7) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91919 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-04-08Fix reading ODF versionSamuel Mehrbrodt1-11/+3
Change-Id: I5787737d3f689fba93bf4be56c018967b5e37ab1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91407 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 1ec7b4ae86a9fe666fc1510636c483d8980d04f6) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91918 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-04-08Related tdf#97694 Show dialog when signed macros are blockedSamuel Mehrbrodt1-1/+19
Change-Id: I7b9dd4872a58eff93ab8818f0286781c6ff4c9bd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91385 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 6c89715b7d1e78a17b6c53cdb89f2f734500fd44) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91917 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-04-08Related tdf#97694 Check Base macro signatures on loadSamuel Mehrbrodt9-50/+128
Change-Id: I45c6eae633c41585c6c7e4c5fff0b187a6dc1f60 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90908 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit f2f93434f4795646255e5d8edd31fa08b8b2ffab) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91916 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-04-07tdf#130648 add colibre 32px protect iconsandreas kainz4-0/+27
Change-Id: I5c1d2a37f88745820cbae693a1e9897c922de13c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88981 Tested-by: Jenkins Reviewed-by: andreas_kainz <kainz.a@gmail.com> (cherry picked from commit 55981cd0bea950a24b89059c22bc291877205419)
2020-04-07tdf#130648 Add icons for ProtectField and PrtectBookmarksandreas kainz8-0/+55
Change-Id: I064c9ac69b224937b281ea5c9a1eefc3cdfeba6d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88894 Tested-by: Jenkins Reviewed-by: andreas_kainz <kainz.a@gmail.com> (cherry picked from commit 2d1994dc01f162ccab68abab45ef3cce381aacbd) Only adding _new_ protect icons here. Change-Id: I1be7ee9874f16faf0631f62a01445e930bf65d22 Conflicts: icon-themes/colibre_svg/cmd/sc_protect.svg
2020-04-07tdf#130648:+ icons for new .uno:ProtectBookmarks & .uno:ProtectFieldsrizmut72-0/+38
Change-Id: Ie9bee00bec79f2bc1d85e5e17556676e71842ef7 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88757 Tested-by: Jenkins Reviewed-by: Rizal Muttaqin <riz_17_oke@yahoo.co.id> (cherry picked from commit 7415a70e3387b36c6e67cab21b4310d4e5f56e1b) Only adding _new_ protect icons here. Change-Id: I7c4020e9e59d3bcb1280681e18d4d8b1e8253180 Conflicts: icon-themes/breeze/cmd/32/safemode.png icon-themes/breeze/cmd/32/sourcecharstyle.png icon-themes/breeze_svg/cmd/32/safemode.svg icon-themes/breeze_svg/cmd/32/sourcecharstyle.svg icon-themes/elementary_svg/cmd/lc_insertfield.svg icon-themes/elementary_svg/cmd/sc_toolprotectiondocument.svg icon-themes/karasa_jaga_svg/cmd/32/subscript.svg icon-themes/karasa_jaga_svg/cmd/32/superscript.svg icon-themes/karasa_jaga_svg/cmd/lc_subscript.svg icon-themes/karasa_jaga_svg/cmd/lc_superscript.svg icon-themes/karasa_jaga_svg/cmd/sc_subscript.svg icon-themes/karasa_jaga_svg/cmd/sc_superscript.svg
2020-04-07Add uno cmd to protect bookmarks in a documentSamuel Mehrbrodt4-3/+35
Change-Id: I7cc0dfa2b129d69d49b555495d77c2c710689e94 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88586 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 4a5c627e61dc1bd67106a18319eabecb50b79658) Without the WriterCommands/UI changes. Change-Id: Ib1d28f96bd1c4a87ef644a376cefa2cf5c7e6728 Conflicts: officecfg/registry/data/org/openoffice/Office/UI/WriterCommands.xcu sw/sdi/_textsh.sdi sw/sdi/swriter.sdi
2020-04-07Add uno cmd to protect fields in a documentSamuel Mehrbrodt4-0/+43
Change-Id: Ifb9f757111a6fcbb283d2350ed2ccd42de19d5df Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88585 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 087d9191ab642e4b00afb71571d83ffe04589769) Without the WriterCommands string/UI changes. Change-Id: I8f8a88bf7624438923b5f611549c703e304763b5 Conflicts: officecfg/registry/data/org/openoffice/Office/UI/WriterCommands.xcu sw/inc/cmdid.h sw/sdi/_textsh.sdi sw/sdi/swriter.sdi sw/source/uibase/shells/textsh1.cxx
2020-03-27tdf#131522 get notified when user edits in OMultilineEditControlThorsten Behrens1-0/+1
Change-Id: I2a9e080143a1aa37661ef2aef8c0d37c8e774c8c
2020-03-26sw: SwEditWin: for CUT of a read-only selection, pop up info dialogMichael Stahl1-1/+3
... as is already done for PASTE, so the user doesn't wonder why it doesn't work. Change-Id: I4c967fdf46bc76f0930d665cf84ca27ef92c00d6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91142 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit b6fb2719170d1d96fc60305d73663ddd81d887e5)
2020-03-26tdf#119016 Editing a read-only section shall popup a dialogIlhan Yesil1-1/+7
While processing the key input, an additional if statement for the paste command (Ctrl+V) is added. Change-Id: If205589256855422ac93f8a5ed8a1ee394ca9310 Reviewed-on: https://gerrit.libreoffice.org/58360 Tested-by: Jenkins Reviewed-by: Michael Stahl <Michael.Stahl@cib.de> (cherry picked from commit 66838c2418df4d016be0da0ef1c7e54934c03421)
2020-03-26sw: PROTECT_FIELDS should not protect placeholder fieldsMichael Stahl1-1/+3
The text placeholder field becomes totally nonfunctional, the other placeholder fields allow inserting but are then not deleted; just ignore protection for placeholder fields. Change-Id: Ic478a32d616464bfe7f24fc851c1998b5e01a23b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91140 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 3fc68fdc6f4ef04091db2fd46499a10396c3a4f2)
2020-03-25sw: Optionally disable bookmark manipulation GUIsKatarina Behrens4-17/+27
If the ProtectBookmarks bit is set, don't allow bookmark changes, neither via the bookmark dialog nor the navigator. Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87361 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit cb5d18871b46ef4f7bc47eb4d71df5374d712575) Omit new strings for backport to 6.1 branch, was only shown as disabled context menu item anyway. Change-Id: I035faaf3871c7107dd1aac38c4e6867291827346
2020-03-25sw: read-only/protected content dialog was missing on Delete/BackspaceMichael Stahl1-0/+12
If SwWrtShell::DelRight()/DelLeft() are called without an active selection, they select 1 character to the right/left, but then they don't check if the selection is read-only, so then SwEditShell::Delete() calls HasReadonlySel() and silently returns. Pop up the dialog in this case too, for consistency. Change-Id: I3d72f136f4d132de3f8a6f3cc2aab493ced95a28 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88055 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 0788ab19869aa2ae5f7fbef9e3c13ceb641f80ee)
2020-03-25sw: implement protection of bookmarks and fieldsMichael Stahl4-49/+145
SwPaM::HasReadonlySel() checks PROTECT_BOOKMARKS / PROTECT_FIELDS setting and checks if bookmarks or fields are selected for deletion. This should already be called by the UI code in all the right places, for the other content protection features, and cause a dialog to pop up. What's not ideal about this is that it's impossible to delete a character immediately before or after a point bookmark because that would delete the point bookmark too. The bookmark check is done by extracting a function out of MarkManager::deleteMarks() so both will use the same logic. The problem of DelContentIndex() duplicating that logic remains... Apparently the status bar at the bottom already displays "read-only" for such a selection. Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87778 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 9e7b5c74b484fcfd3317db56745b26b10897047d) Change-Id: Id87999198a03ba847ef0eff5651fef3bd2517fae
2020-03-25sw: split into 2 settings ProtectBookmarks and ProtectFieldsMichael Stahl4-12/+37
On second thought, let's have 2 settings because there might be some use-case for protecting one but not the other. Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87777 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 249b10c22f4a35672a7388d34b2ded1b76054dac) Change-Id: If8442b64adeeed80b25c8b69f607f2d4993786e4
2020-03-25Add ProtectBookmarksAndFields per-document optionKatarina Behrens4-1/+26
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87360 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit a5cd4d39f09c3658c2b7cfff4ab6a74449d4f0c0) Change-Id: I8dac403ddea59026b5f52c132c8accc1bd0ada92
2020-03-25Remove option to build against system PythonThorsten Behrens1-13/+4
With python3: upgrade to release 3.5.9 we only support internal python builds on this LTS branch. Change-Id: Ib7f9ab86c767b76a94b350b8ab0bcd413a8b2a62
2020-03-25icu: add patch to fix CVE-2020-10531Michael Stahl3-1/+42
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90971 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 002d1152dc418f7d624409e76cd9d4ac0b42c7f8) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90975 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 63b573faf984875cda7a879e696ea75fae81df57) Change-Id: I0aca4af1bd79f28bf1c920a4d05e80948106aaac
2020-03-16Some more checks for correct screen sizeSamuel Mehrbrodt2-2/+19
Change-Id: Id5a811e4227052fd9117ab2b099de31e8e3b90c2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90413 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 3741d70743c297029f54b20b0ca711f40cff7097) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90576 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-03-16Add some fallback minimum size when screen size detection goes wrongSamuel Mehrbrodt1-0/+7
Change-Id: I97ec2359b8ae406e310a5d043ac068ddd89b3fd1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90320 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 643a1492bd648fbd803ca86aca600cc2bdaf5819) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90575 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-03-13Bump version to 6.1.7.11cib-6.1-11Thorsten Behrens1-1/+1
Change-Id: Ic32b4f944219577732a98babdb10d4027cf03bae
2020-03-13tdf#42316 always evaluate macro signatures on loadJan-Marek Glogowski2-24/+9
As already stated in the comments of the signing unit tests, disabling macro security will not only ignore the signatures, but actually drop the macro signature, as these are never evaluated and as a result can't be restored for the new document. Change-Id: Ie41a9e72d3367c2eed58a52387bb67d8c41abff3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90435 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 929d46bbf42aefc1f6cf046c2b9cf3d7c4e1efc5) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90393 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-03-12comphelper: fix build against CentOS6 baselineThorsten Behrens1-2/+2
Change-Id: Ice8a27dc92c923b3d2c62a6989e13720ff044749
2020-03-11Bump version to 6.1.7.10cib-6.1-10Thorsten Behrens1-1/+1
Change-Id: I45f327df9f6ba5f4e617a15b80a0abb7f713781e
2020-03-11WIN prevent deadlock in SetForegroundWindowJan-Marek Glogowski1-9/+55
As mentioned in various blogs, like Raymon Chens "The old new thing", 2008-08-01, "I warned you: The dangers of attaching input queues", using AttachThreadInput to steal the input from an other thread, so SetForegroundWindow becomes more reliable, can deadlock in that call in win32u.dll!NtUserCallHwndLock. Stackoverflow also has a multitude of suggestions and links in "Win32 SetForegroundWindow unreliable", to circumvent Windows focus-stealing prevention mechanisms. A customer is experiencing these hangs reliably and often when opening LO windows via Java UNO, because the Window and the UNO thread are different and trigger this code path. Removing the calls to AttachThreadInput fixes the problem for them. This has started lately and nobody really knows why. I also know other customers with a similar Java UNO setup, which don't experience them. For better foreground handling, the calling app eventually should either use AllowSetForegroundWindow or CoAllowSetForegroundWindow (for COM servers), to give up the foreground / input handling. This is plus: WIN add bootstrap var to re-enable foreground hack We already found a regressed installation from commit 518c0265efebf39ab6d1e90c4ec4e7cf52b701c6 ("WIN prevent deadlock in SetForegroundWindow"). Finding a real fix might be impossible, so this just adds the bootstrap.ini boolean variable Win32.EnableAttachThreadInputHack to re-enable the previous AttachThreadInput hack on demand. Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90235 Change-Id: I8de0a17aaaa44c24b1ee728b2ef6ec3aea951c54 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89518 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-03-11tdf#131000 fix stuck combo box property editorJan-Marek Glogowski2-3/+2
If you create a combo box control with a lot of entries, like a large cell range in Calc, LO will take a long time to render that cell content into the small, line-height MultiLineEdit (MLE). This doesn't happen for master, because it contains commit 1efeb17837c22499f00299c033ae59ba3910f7d7 ("weld Property Browser"), which changed the whole dialog and is much too large for a backport. A debugger shows LO is stuck in TextEngine:: CreateLines, which is part of the MLE resize call stack. Checking the master patch, it also replaces the MLE with a mere Edit. And since editing now always happens in the popup, no functionality is lost. So this patch just does just that MLE => Edit replacement for old releases. This results in a much faster visible / usable property editor. For the attached test document with 4000 entries, resize time goes down to 5s instead of minutes. Fun fact: since you can't actually edit that entry in the example bug document, because its content depends on Cell data, all the "work" is basically mood. Change-Id: I7583e0ed1a70765c9f3bd7ff730e920a833bf30b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89417 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 3269f4fa5477104fbea363937ec84dfab2f914d9) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/90219
2020-02-10breakpad: fix build against CentOS6 baselineThorsten Behrens1-1/+1
Change-Id: I7f7e88bb37c945e2f01ea60af7dc2a301aa5d6b0
2020-02-10Bump version to 6.1.7.9cib-6.1-9Thorsten Behrens1-1/+1
Change-Id: I6383689734a83a71ec90806dc12726168e89a612
2020-02-09tdf#93389: keep encryption information for autorecovered MS formatsMike Kaganski5-6/+65
The autorecovery data is stored in ODF, regardless of the original document format. When restoring, type detection generates ODF data, which is stored in the media descriptor attached to document, even after real filter was restored (see AutoRecovery::implts_openDocs). If real filter is not ODF, then at the save time, it doesn't find necessary information in encryption data, and makes not encrypted package. This patch adds both MS binary data, and OOXML data, to existing ODF data for recovered password-protected documents (regardless of their real filter). TODO: only add required information to encryption data: pass real filter name to DocPasswordHelper::requestAndVerifyDocPassword from AutoRecovery::implts_openDocs. Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86201 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit dd198398b6e5c84ab1255a90ef96e6445b66a64f) Conflicts: comphelper/source/misc/docpasswordhelper.cxx Change-Id: I4717f067ad3c40167312b99eefef5584a467bfed (cherry picked from commit 6017cdff264afc3b98beeba1330d6df28102fe7a)
2020-02-09tdf#118639: store ODF encryption data for autorecoveryMike Kaganski2-8/+40
When saving autorecovery information, ODF is used. If the original document is password-protected, its autorecovery is also generated password-protected (since ef87ff6680f79362a431db6e7ef2f40cfc576219). But when the stored encryption data for non-ODF document does not contain "PackageSHA256UTF8EncryptionKey" value, following ZipPackage::GetEncryptionKey fails, so the whole save fails. So just generate and append ODF encryption keys where we still have user password. Reviewed-on: https://gerrit.libreoffice.org/84052 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 63634738dd03cc74806ce6843c16ff5e51a371a0) Reviewed-on: https://gerrit.libreoffice.org/84133 Reviewed-by: Xisco Faulí <xiscofauli@libreoffice.org> (cherry picked from commit e569dc9824e95617d921bb8f115d243aea0125b9) Reviewed-on: https://gerrit.libreoffice.org/84232 Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com> (cherry picked from commit d1450f5bddd0f108078e0dfb11c9f130175fafe7) Conflicts: comphelper/source/misc/docpasswordhelper.cxx Change-Id: I776e28de784489521e4941d1075690f90c056014
2020-02-07neon: escape broken SharePoint 2016 URIsJan-Marek Glogowski2-0/+23
SharePoint returns broken URIs in its href replies, which aren't correctly URI encoded, but still "valid" URIs w.r.t. general and UTF8 encoding, e.g. http://<host>/Shared%20Documents/ümlaut.docx As a workaround, this allows all invalid / other bytes (except '\0') in the path of the URI in ne_uri_parse. Change-Id: I70e7d323837469d7ced429a42c009972f4fb0ebc Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88120 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> Tested-by: Jenkins (cherry picked from commit 069aa870aadb9f9069e8715c8be30394410f0288) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88200 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-02-07Remove a fragment from a file URL early onStephan Bergmann1-2/+4
...as ShellExecuteExW would ignore it anyway Change-Id: I969db094bb7d2ea230ac8c36eb23d71a90fbe466 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86868 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> (cherry picked from commit 14b36a16b225bf7c988f118d499a7287c47cd83e) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/86875 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit e033f200d74202d64f4a928c2d7b3b1cadd1c8e8) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88203 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-02-04tdf#125440 When inserting TSV, consider quotes as field markersSamuel Mehrbrodt1-1/+3
The problem is that this is "plain text" from the clipboard format, but actually contains TSV (tab separated values). So treat them accordingly, so that each value gets its own cell. Change-Id: I0029e6ace90fc542c3269dd82bb7531654157a69 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87950 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-02-04Unit test for stable at-page anchored fly positionJan-Marek Glogowski5-2/+54
This is the unit test for commit 5cee586a97a11c23dd252accc42099bd5e9b4187 ("sw: fix moving of at-page anchored flys to different page"). Originally the error was just triggered by toggling "View -> Field Names". Luckily it's also triggered by adding some text to page four, so no need for some UI test. Change-Id: I3a63b50dd898788607c3d24a848d8f43ae966377 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87776 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 5fed8bb5f6f65963fed27f96de3be14dff830d38) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87847 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 4db184ea279a2974679b05eaa8ca52ec087f68af) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/87983 Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-01-21tdf#129311 don't allow temporary trusted certsJan-Marek Glogowski2-3/+16
This simply skips the DocumentMacroConfirmationRequest, if the macro security level (MSL) is *High* and the list of trusted authors is read-only. For the MSL *Medium*, the check box of the dialog is hidden with read-only trusted authors. Change-Id: If6c08e4fdbf200e778d181370cc73fd947cecff5 Reviewed-on: https://gerrit.libreoffice.org/84887 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit 71c6f438cecc3ce5e8060efe1df840652885701c) Reviewed-on: https://gerrit.libreoffice.org/85299 (cherry picked from commit 9cdb97cd93e60a0faf0a531949d94cff79e1aab9) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85757 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2020-01-21Fix macro security UI usability problemsJan-Marek Glogowski5-38/+48
* Don't hide the option dialogs "Macro security" push button. I don't see any reason, why these settings should be hidden, if macros are disabled or settings locked. At least a user can now check, what is going on (still nothing shows disabled macros for a document in the UI AFAIK). * Don't scale the lock icons of the trusted list boxes. This just uses the same alignments, which the macro security level lock image uses, otherwise the image is scaled to fit the whole space of its layout cell. * Don't disable the trusted list boxes. If the setting is locked, it's sufficient to disable all the buttons, which allow modification (so View can stay enabled). This way you can still scroll the list. Correct button handling is already implemented and works for me. * Catch exceptions of broken certificate data. If your config contains certificates, which can't be correctly decoded, the NSS backend will throw an exception, which kills the dialog, but not the nested loop, resulting in a locked LO. Since we don't want a string change in LTS, this drops the whole "broken certificate" warning dialog. There already are SAL_WARNs, which log the same warning, and are considered sufficient for debugging broken configurations. Reviewed-on: https://gerrit.libreoffice.org/85056 Tested-by: Jenkins Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de> (cherry picked from commit b3348ce498b3d54b3e5e6518954ad9d5e917b8f2) Reviewed-on: https://gerrit.libreoffice.org/85282 (cherry picked from commit ad1a41032054991cfb8b9e821c1dd25ec21d0aec) Change-Id: I79002e0ce85cf9a9017caf858407f2f635a3a074 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85756 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2019-12-23sw: fix widow loop with as-char flys in text formattingMichael Stahl3-5/+7
The document has a paragraph with 4 as-character anchored flys depicting Zirbenholz; due to their size and an additional fly that is anchored at the paragraph, there are 3 lines that do not fit onto a single page. This situation causes a loop that proceeds like this: text frame 80 is the follow of text frame 21. when formatting 80: the 1 line violates the widow rule (>=2) and PREP_WIDOWS is sent to 21, invalidating its FrameAreaSize 80 validates its FrameAreaSize when formatting 21: PREP_WIDOWS_ORPHANS sent to 21 CalcPreps() sees IsPrepWidows() and sets a huge height and calls SetWidow(true) SwTextFrame::WouldFit() sees IsWidow() true and resets it false SwTextFrame::WouldFit() sees IsWidow() false and a huge but insufficiently huge height 21 validates its FrameAreaSize CalcPreps() sees IsPrepAdjust() FindBreak() calls TruncLines() and because of as-char fly invalidates FrameAreaSize of 80 The loop is most easily reproduced by printing via the API; it's possible to get a loop when loading the document in the UI, but typically the UI remains responsive even though the layout never finishes. As it happens, before commit ee299664940139f6f9543592ece3b3c0210b59f4 "SalInstance::DoYield: Don't drop SolarMutex when accessing user event queue" the loop on printing via API was broken by releasing SolarMutex; the result, however, was incorrect, with the last line of Zirbenholz that should be on the second page missing in the PDF. This loop is presumably a regression from commit f2e3655255db4032738849cd4b77ce67a6e2c984 "Avoid -fsanitize=signed-integer-overflow", which changed a magic number in SwTextFrame::CalcPreps(), but didn't adapt the poorly documented corresponding magic numbers in SwTextFrame::WouldFit(); in LO 5.1.6.2 the CPU is idle after loading the document. Change-Id: Ib6563c21edb68945c14a61b51ba34f0ee3f2544a Reviewed-on: https://gerrit.libreoffice.org/85623 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@cib.de> (cherry picked from commit 68a5afaaabd0c75bba3439cfdff90fb75d1cdd3f)
2019-12-23tdf#126127: Make nTmp smaller still, avoid -fsanitize=signed-integer-overflowStephan Bergmann1-1/+8
...after f2e3655255db4032738849cd4b77ce67a6e2c984 "Avoid -fsanitize=signed-integer-overflow" had already reduced it from using LONG_MAX to TWIPS_MAX/2 in the past. This time, avoid the computation of > const sal_uInt64 nCurrentDist = sal_Int64(aDiff.getX()) * sal_Int64(aDiff.getX()) + sal_Int64(aDiff.getY()) * sal_Int64(aDiff.getY()); // opt: no sqrt in GetFrameOfModify (sw/source/core/layout/frmtool.cxx) from overflowing (where aDiff.getY() derives from nTmp and can be close to it in magnitude, so computing its square would overflow on platforms where TWIPS_MAX is a large sal_Int64 value). (The "empirically shown to be large enough in practice" in the comment is a successful `make check` on Linux 64-bit with UBSan.) Change-Id: Ic7f058bd6853ff04ccb50a150509e98f850d12d2 Reviewed-on: https://gerrit.libreoffice.org/74801 Reviewed-by: Michael Stahl <michael.stahl@cib.de> Tested-by: Jenkins (cherry picked from commit 8723ac4e20eda87a82393f2f6c7d28ece8514238)
2019-12-20Bump version to 6.1.7.8cib-6.1-8Thorsten Behrens1-1/+1
Change-Id: I1237c4502d5b7f46fc510fce00377c8cce8dbcf0
2019-12-20tdf#129519 Fix crash during WebDAV lock refreshThorsten Behrens2-0/+23
- NeonSession is shared amongst several files (if on the same server instance) - there's explicit code in DAVSessionFactory::createDAVSession() to share sessions for same host/target - so then after a while, locks get refreshed, and session timeout hits - first lock -> no prob, ne_auth.c:ah_post_send() has auth_challenge() failing, returning error, which puts that lock into m_aRemoveDeferred list - _but_ ah_post_send() then does a clean_session(), and the next lock refresh from the same session hits NULLPTR session host -> so let's delay any sspi_host cleanup until session object gets freed, instead of just cleaned Change-Id: Ie257310c47913aef9fcfec92c1722d64b28c4f89 Reviewed-on: https://gerrit.libreoffice.org/85614 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2019-12-18tdf#125207 Extend css.awt.PrinterServer: XPrinterServer2brinzing4-4/+60
This change doesn't have the API incompatibility which the master change has (change in PrinterServer service). Change-Id: Ic2df8ac676ae786d9c0ea2ab3619f9f9de087ca7 Reviewed-on: https://gerrit.libreoffice.org/72135 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com> (cherry picked from commit 0f55127195a897ca7b13c25ded2208476dba3a08) Reviewed-on: https://gerrit.libreoffice.org/85035 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2019-12-18tdf#126279 related: remove locks from NeonLockStore after NE_AUTH errorMike Kaganski3-1/+15
Change-Id: Idbbb9bb215e3a56e72a29f798c5a5f84afaf2213 Reviewed-on: https://gerrit.libreoffice.org/75224 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 94e4695bcfcb9356d37942c47359b94531ef7b95)
2019-12-18tdf#126279: reinitialize session after NE_AUTH errors in (UN)LOCKMike Kaganski1-2/+14
This just fixes the crash; but there's still a problem left/TODO, because the lock is kept registered with NeonLockStore; following attempts to lock and unlock fail. The NE_AUTH error is returned from this call stack: neon.dll!clean_session(auth_session * sess) Line 275 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_auth.c(275) neon.dll!ah_post_send(ne_request_s * req, void * cookie, const ne_status * status) Line 1554 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_auth.c(1554) neon.dll!ne_end_request(ne_request_s * req) Line 1399 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_request.c(1399) neon.dll!ne_xml_dispatch_request(ne_request_s * req, ne_xml_parser_s * parser) Line 105 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_xmlreq.c(105) neon.dll!ne_lock_refresh(ne_session_s * sess, ne_lock * lock) Line 849 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_locks.c(849) ucpdav1.dll!webdav_ucp::NeonSession::LOCK(ne_lock * pLock, long & rlastChanceToSendRefreshRequest) Line 1663 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\NeonSession.cxx(1663) ucpdav1.dll!webdav_ucp::NeonLockStore::refreshLocks() Line 216 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\NeonLockStore.cxx(216) ucpdav1.dll!webdav_ucp::TickerThread::execute() Line 78 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\NeonLockStore.cxx(78) salhelper3MSC.dll!salhelper::Thread::run() Line 40 at C:\cygwin\home\user\lode\dev\core\salhelper\source\thread.cxx(40) salhelper3MSC.dll!threadFunc(void * param) Line 186 at C:\cygwin\home\user\lode\dev\core\include\osl\thread.hxx(186) sal3.dll!oslWorkerWrapperFunction(void * pData) Line 58 at C:\cygwin\home\user\lode\dev\core\sal\osl\w32\thread.cxx(58) ucrtbased.dll!thread_start<unsigned int (__cdecl*)(void *),1>(void * const parameter) Line 97 at minkernel\crts\ucrt\src\appcrt\startup\thread.cpp(97) kernel32.dll!BaseThreadInitThunk() ntdll.dll!RtlUserThreadStart() If not reinitialized, then on next access, it SEGFAULTs (hostname is nullptr): neon.dll!ne_addr_resolve(const char * hostname, int flags) Line 926 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_socket.c(926) neon.dll!canonical_hostname(const char * serverName) Line 382 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_sspi.c(382) neon.dll!ne_sspi_create_context(void * * context, char * serverName, int ntlm) Line 423 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_sspi.c(423) neon.dll!continue_sspi(auth_session * sess, int ntlm, const char * hdr, int attempt, auth_challenge * parms, ne_buffer * * errmsg) Line 639 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_auth.c(639) neon.dll!sspi_challenge(auth_session * sess, int attempt, auth_challenge * parms, ne_buffer * * errmsg) Line 675 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_auth.c(675) neon.dll!auth_challenge(auth_session * sess, int attempt, const char * value) Line 1419 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_auth.c(1419) neon.dll!ah_post_send(ne_request_s * req, void * cookie, const ne_status * status) Line 1550 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_auth.c(1550) neon.dll!ne_end_request(ne_request_s * req) Line 1399 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_request.c(1399) neon.dll!ne_request_dispatch(ne_request_s * req) Line 1458 at C:\cygwin\home\user\lode\dev\core\workdir\UnpackedTarball\neon\src\ne_request.c(1458) ucpdav1.dll!webdav_ucp::NeonSession::OPTIONS(const rtl::OUString & inPath, webdav_ucp::DAVOptions & rOptions, const webdav_ucp::DAVRequestEnvironment & rEnv) Line 913 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\NeonSession.cxx(913) ucpdav1.dll!webdav_ucp::DAVResourceAccess::OPTIONS(webdav_ucp::DAVOptions & rOptions, const com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> & xEnv) Line 187 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\DAVResourceAccess.cxx(187) ucpdav1.dll!webdav_ucp::Content::getResourceOptions(const com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> & xEnv, webdav_ucp::DAVOptions & rDAVOptions, const std::unique_ptr<webdav_ucp::DAVResourceAccess,std::default_delete<webdav_ucp::DAVResourceAccess> > & rResAccess, bool * networkAccessAllowed) Line 3940 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\webdavcontent.cxx(3940) ucpdav1.dll!webdav_ucp::Content::getProperties(const com::sun::star::uno::Reference<com::sun::star::ucb::XCommandEnvironment> & xEnv) Line 323 at C:\cygwin\home\user\lode\dev\core\ucb\source\ucp\webdav-neon\webdavcontentcaps.cxx(323) ucbhelper.dll!ucbhelper::PropertySetInfo::getProperties() Line 106 at C:\cygwin\home\user\lode\dev\core\ucbhelper\source\provider\contentinfo.cxx(106) ucbhelper.dll!ucbhelper::PropertySetInfo::queryProperty(const rtl::OUString & rName, com::sun::star::beans::Property & rProp) Line 187 at C:\cygwin\home\user\lode\dev\core\ucbhelper\source\provider\contentinfo.cxx(187) ucbhelper.dll!ucbhelper::PropertySetInfo::hasPropertyByName(const rtl::OUString & Name) Line 168 at C:\cygwin\home\user\lode\dev\core\ucbhelper\source\provider\contentinfo.cxx(168) sfxlo.dll!SfxBaseModel::getBoolPropertyValue(const rtl::OUString & rName) Line 2582 at C:\cygwin\home\user\lode\dev\core\sfx2\source\doc\sfxbasemodel.cxx(2582) sfxlo.dll!SfxBaseModel::isVersionable() Line 2599 at C:\cygwin\home\user\lode\dev\core\sfx2\source\doc\sfxbasemodel.cxx(2599) sfxlo.dll!SfxObjectShell::GetState_Impl(SfxItemSet & rSet) Line 1133 at C:\cygwin\home\user\lode\dev\core\sfx2\source\doc\objserv.cxx(1133) sfxlo.dll!SfxStubSfxObjectShellGetState_Impl(SfxShell * pShell, SfxItemSet & rSet) Line 220 at C:\cygwin\home\user\lode\dev\core\workdir\SdiTarget\sfx2\sdi\sfxslots.hxx(220) sfxlo.dll!SfxShell::CallState(void(*)(SfxShell *, SfxItemSet &) pFunc, SfxItemSet & rSet) Line 199 at C:\cygwin\home\user\lode\dev\core\include\sfx2\shell.hxx(199) sfxlo.dll!SfxShell::GetSlotState(unsigned short nSlotId, const SfxInterface * pIF, SfxItemSet * pStateSet) Line 480 at C:\cygwin\home\user\lode\dev\core\sfx2\source\control\shell.cxx(480) sfxlo.dll!SfxDispatcher::QueryState(unsigned short nSID, com::sun::star::uno::Any & rAny) Line 1967 at C:\cygwin\home\user\lode\dev\core\sfx2\source\control\dispatch.cxx(1967) sfxlo.dll!SfxDispatchController_Impl::addStatusListener(const com::sun::star::uno::Reference<com::sun::star::frame::XStatusListener> & aListener, const com::sun::star::util::URL & aURL) Line 832 at C:\cygwin\home\user\lode\dev\core\sfx2\source\control\unoctitm.cxx(832) sfxlo.dll!SfxOfficeDispatch::addStatusListener(const com::sun::star::uno::Reference<com::sun::star::frame::XStatusListener> & aListener, const com::sun::star::util::URL & aURL) Line 252 at C:\cygwin\home\user\lode\dev\core\sfx2\source\control\unoctitm.cxx(252) fwklo.dll!framework::MenuBarManager::Activate(Menu * pMenu) Line 756 at C:\cygwin\home\user\lode\dev\core\framework\source\uielement\menubarmanager.cxx(756) fwklo.dll!framework::MenuBarManager::LinkStubActivate(void * instance, Menu * data) Line 605 at C:\cygwin\home\user\lode\dev\core\framework\source\uielement\menubarmanager.cxx(605) vcllo.dll!Link<Menu *,bool>::Call(Menu * data) Line 112 at C:\cygwin\home\user\lode\dev\core\include\tools\link.hxx(112) vcllo.dll!Menu::Activate() Line 270 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\menu.cxx(270) vcllo.dll!PopupMenu::ImplExecute(const VclPtr<vcl::Window> & pW, const tools::Rectangle & rRect, FloatWinPopupFlags nPopupModeFlags, Menu * pSFrom, bool bPreSelectFirst) Line 2876 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\menu.cxx(2876) vcllo.dll!MenuBarWindow::ImplCreatePopup(bool bPreSelectFirst) Line 339 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\menubarwindow.cxx(339) vcllo.dll!MenuBarWindow::ChangeHighlightItem(unsigned short n, bool bSelectEntry, bool bAllowRestoreFocus, bool bDefaultToDocument) Line 558 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\menubarwindow.cxx(558) vcllo.dll!MenuBarWindow::MouseButtonDown(const MouseEvent & rMEvt) Line 403 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\menubarwindow.cxx(403) vcllo.dll!ImplHandleMouseEvent(const VclPtr<vcl::Window> & xWindow, MouseNotifyEvent nSVEvent, bool bMouseLeave, long nX, long nY, unsigned __int64 nMsgTime, unsigned short nCode, MouseEventModifiers nMode) Line 700 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\winproc.cxx(700) vcllo.dll!ImplHandleSalMouseButtonDown(vcl::Window * pWindow, const SalMouseEvent * pEvent) Line 2017 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\winproc.cxx(2017) vcllo.dll!ImplWindowFrameProc(vcl::Window * _pWindow, SalEvent nEvent, const void * pEvent) Line 2351 at C:\cygwin\home\user\lode\dev\core\vcl\source\window\winproc.cxx(2351) vcllo.dll!SalFrame::CallCallback(SalEvent nEvent, const void * pEvent) Line 299 at C:\cygwin\home\user\lode\dev\core\vcl\inc\salframe.hxx(299) vclplug_winlo.dll!ImplHandleMouseMsg(HWND__ * hWnd, unsigned int nMsg, unsigned __int64 wParam, __int64 lParam) Line 3132 at C:\cygwin\home\user\lode\dev\core\vcl\win\window\salframe.cxx(3132) vclplug_winlo.dll!SalFrameWndProc(HWND__ * hWnd, unsigned int nMsg, unsigned __int64 wParam, __int64 lParam, bool & rDef) Line 5487 at C:\cygwin\home\user\lode\dev\core\vcl\win\window\salframe.cxx(5487) vclplug_winlo.dll!SalFrameWndProcW(HWND__ * hWnd, unsigned int nMsg, unsigned __int64 wParam, __int64 lParam) Line 5840 at C:\cygwin\home\user\lode\dev\core\vcl\win\window\salframe.cxx(5840) user32.dll!UserCallWinProcCheckWow() user32.dll!CallWindowProcW() opengl32.dll!wglWndProc() user32.dll!UserCallWinProcCheckWow() user32.dll!DispatchMessageWorker() vclplug_winlo.dll!ImplSalDispatchMessage(const tagMSG * pMsg) Line 411 at C:\cygwin\home\user\lode\dev\core\vcl\win\app\salinst.cxx(411) vclplug_winlo.dll!ImplSalYield(bool bWait, bool bHandleAllCurrentEvents) Line 484 at C:\cygwin\home\user\lode\dev\core\vcl\win\app\salinst.cxx(484) vclplug_winlo.dll!WinSalInstance::DoYield(bool bWait, bool bHandleAllCurrentEvents) Line 513 at C:\cygwin\home\user\lode\dev\core\vcl\win\app\salinst.cxx(513) vcllo.dll!ImplYield(bool i_bWait, bool i_bAllEvents) Line 447 at C:\cygwin\home\user\lode\dev\core\vcl\source\app\svapp.cxx(447) vcllo.dll!Application::Yield() Line 512 at C:\cygwin\home\user\lode\dev\core\vcl\source\app\svapp.cxx(512) vcllo.dll!Application::Execute() Line 428 at C:\cygwin\home\user\lode\dev\core\vcl\source\app\svapp.cxx(428) sofficeapp.dll!desktop::Desktop::Main() Line 1620 at C:\cygwin\home\user\lode\dev\core\desktop\source\app\app.cxx(1620) vcllo.dll!ImplSVMain() Line 191 at C:\cygwin\home\user\lode\dev\core\vcl\source\app\svmain.cxx(191) vcllo.dll!SVMain() Line 226 at C:\cygwin\home\user\lode\dev\core\vcl\source\app\svmain.cxx(226) sofficeapp.dll!soffice_main() Line 170 at C:\cygwin\home\user\lode\dev\core\desktop\source\app\sofficemain.cxx(170) soffice.bin!sal_main() Line 48 at C:\cygwin\home\user\lode\dev\core\desktop\source\app\main.c(48) soffice.bin!main(int argc, char * * argv) Line 47 at C:\cygwin\home\user\lode\dev\core\desktop\source\app\main.c(47) soffice.bin!invoke_main() Line 79 at d:\agent\_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(79) soffice.bin!__scrt_common_main_seh() Line 288 at d:\agent\_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(288) soffice.bin!__scrt_common_main() Line 331 at d:\agent\_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_common.inl(331) soffice.bin!mainCRTStartup() Line 17 at d:\agent\_work\2\s\src\vctools\crt\vcstartup\src\startup\exe_main.cpp(17) kernel32.dll!BaseThreadInitThunk() ntdll.dll!RtlUserThreadStart() Change-Id: I632d85b65406e29ad0e3d56d8481c651c64b2ec8 Reviewed-on: https://gerrit.libreoffice.org/75194 Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 351b730e012fd4562f341967f740f8146aa0538e)
2019-12-18Don't crash when accessing WebDAV resource after auth failedMike Kaganski3-8/+17
In my testing on Windows, the crashing scenario was this: 1. FileDialogHelper_Impl::updateVersions() creates storage calling comphelper::OStorageHelper::GetStorageFromURL; 2. Content::openStream() calls isDocument first; 3. Content::isDocument() indirectly initiates WebDAV session, creating a NeonSession; 4. All operations of NeonSession call Init() first; its first call initializes m_pHttpSession using ne_session_create, and then adds auth callbacks using ne_add_server_auth/ne_add_proxy_auth 5. Then NeonSession performs the rest of PROPFIND task, calling ah_post_send and auth_challenge; the latter fails, then ah_post_send calls clean_session, which cleans m_pHttpSession's auth_session's sspi_host; 6. NeonSession::HandleError throws DAVException for NE_AUTH error; 7. Content::isDocument() returns true to Content::openStream(), which proceeds to execute the command, which in turn re-uses the NeonSession and its m_pHttpSession; 8. NeonSession::OPTIONS then indirectly calls continue_sspi, which tries to dereference the m_pHttpSession's auth_session's sspi_host which is nullptr at this point. So in case NeonSession detects the NE_AUTH error condition, let's set a flag indicating that the next Init() should reinitialize its m_pHttpSession. Also fixed a case when xProps was used before initialization in Content::getPropertyValues. Reviewed-on: https://gerrit.libreoffice.org/65950 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> (cherry picked from commit 162a472d55cf9fb9aaa6d5eae625b3da2273a516) Conflicts: ucb/source/ucp/webdav-neon/NeonSession.hxx Change-Id: Ifc9eec4fe0333ff6be17c5089068441b4a6eb78c
2019-12-15Beanshell: Display full exception messageSamuel Mehrbrodt1-1/+1
Useful to see where exactly the error occured Change-Id: I716f54c4b1286d705b52f19a58f36f28a801e1d0 Reviewed-on: https://gerrit.libreoffice.org/69799 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 3d54a104ae97a3218bf58eb38f28c03e26ba7e43) Reviewed-on: https://gerrit.libreoffice.org/85034 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
2019-12-15Beanshell: Wrap long error messagesSamuel Mehrbrodt1-2/+14
Change-Id: I5e607f4b94733700810d37c289f6cc29492da5f2 Reviewed-on: https://gerrit.libreoffice.org/69798 Tested-by: Jenkins Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de> (cherry picked from commit 3c72945de874aceb12a405c03f5b0c8b3937f5cf) Reviewed-on: https://gerrit.libreoffice.org/85033 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> Tested-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>