summaryrefslogtreecommitdiff
path: root/cui/source
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2021-07-27 11:36:48 +0200
committerStephan Bergmann <sbergman@redhat.com>2021-07-27 13:20:24 +0200
commit0aea34da123edc8e1be8626769f0ab83b6d0cab8 (patch)
tree7eecc316b7496bcb837fbb33c4a839acba7f67e2 /cui/source
parent3ba06d93a90c7c97dbb7648931bbb2014b3cf784 (diff)
-Werror=maybe-uninitialized
(at least with recent GCC 12 trunk and --enable-dbgutil --enable-optimized; see the discussion starting in the comment at <https://gerrit.libreoffice.org/c/core/+/109930/11#message-4375e529ca6a843e3560facc591368bf2f36a755> "tdf#114567 tdf#138934 Hyperlink-Target in Doc Headings expand/collapse" for the use of o3tl::doAccess here) Change-Id: I8ecc624488afa8825fe9c60bb07ca7079c398340 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119547 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'cui/source')
-rw-r--r--cui/source/dialogs/hlmarkwn.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx
index 42445b383a51..2d2fb8ac943d 100644
--- a/cui/source/dialogs/hlmarkwn.cxx
+++ b/cui/source/dialogs/hlmarkwn.cxx
@@ -18,6 +18,7 @@
*/
#include <dialmgr.hxx>
+#include <o3tl/any.hxx>
#include <unotools/viewoptions.hxx>
#include <vcl/graph.hxx>
@@ -352,8 +353,7 @@ int SvxHlinkDlgMarkWnd::FillTree( const uno::Reference< container::XNameAccess >
// get the headings outline level
aAny = xTarget->getPropertyValue("OutlineLevel");
- sal_Int32 nOutlineLevel;
- aAny >>= nOutlineLevel;
+ sal_Int32 nOutlineLevel = *o3tl::doAccess<sal_Int32>(aAny);
// pop until the top of stack entry has an outline level less than
// the to be inserted heading outline level