sw/inc/ndindex.hxx |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

New commits:
commit 020d72fb85dac7a52eacb29731b8f2d536a2892d
Author:     Caolán McNamara <caolan.mcnam...@collabora.com>
AuthorDate: Thu Jun 1 09:22:08 2023 +0100
Commit:     Caolán McNamara <caolan.mcnam...@collabora.com>
CommitDate: Thu Jun 1 14:47:03 2023 +0200

    WaE: SwNodeIndex GCC12 spurious -Werror=dangling-pointer=
    
    I see this with gcc 13 too
    
    Change-Id: I63aed9a3bdc5bec7f96474145fd2ba30156741cb
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/152478
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>

diff --git a/sw/inc/ndindex.hxx b/sw/inc/ndindex.hxx
index d700ac11c2f0..775546597500 100644
--- a/sw/inc/ndindex.hxx
+++ b/sw/inc/ndindex.hxx
@@ -36,12 +36,12 @@ class SAL_WARN_UNUSED SW_DLLPUBLIC SwNodeIndex final : 
public sw::Ring<SwNodeInd
         SwNodes& rNodes = GetNodes();
         if(!rNodes.m_vIndices)
         {
-#if defined(__GNUC__) && __GNUC__ == 12
+#if defined(__GNUC__) && (__GNUC__ == 12 || __GNUC__ == 13)
 #pragma GCC diagnostic push
 #pragma GCC diagnostic ignored "-Wdangling-pointer"
 #endif
             rNodes.m_vIndices = this;
-#if defined(__GNUC__) && __GNUC__ == 12
+#if defined(__GNUC__) && (__GNUC__ == 12 || __GNUC__ == 13)
 #pragma GCC diagnostic pop
 #endif
         }

Reply via email to