diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-01-19 11:49:44 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-01-19 11:49:44 +0100 |
commit | 59f190a5ac18a68a60d169e87fab9c335f488da0 (patch) | |
tree | dabb4f3a4639362ada20301d02acf6d206fe2411 | |
parent | b03879a9396c740bca248d9fcc7d8420a414e946 (diff) |
Silence some odd -Werror=strict-overflow (GCC 6)
Change-Id: I7facae62c7ce0977e8c40d60720e4fe32460cd3d
-rw-r--r-- | sw/source/core/text/txtfrm.cxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sw/source/core/text/txtfrm.cxx b/sw/source/core/text/txtfrm.cxx index 0cc84d984de5..dc33a520df47 100644 --- a/sw/source/core/text/txtfrm.cxx +++ b/sw/source/core/text/txtfrm.cxx @@ -681,7 +681,15 @@ sal_Int32 SwTextFrame::FindBrk( const OUString &rText, bool SwTextFrame::IsIdxInside( const sal_Int32 nPos, const sal_Int32 nLen ) const { +// Silence over-eager warning emitted at least by GCC trunk towards 6: +#if defined __GNUC__ && !defined __clang__ +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wstrict-overflow" +#endif if( nLen != COMPLETE_STRING && GetOfst() > nPos + nLen ) // the range preceded us +#if defined __GNUC__ && !defined __clang__ +#pragma GCC diagnostic pop +#endif return false; if( !GetFollow() ) // the range doesn't precede us, |