summaryrefslogtreecommitdiff
path: root/vcl/unx/generic/fontmanager/fontconfig.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-06-17 15:48:38 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-06-18 13:33:18 +0200
commitf11195aa32035ceeb1271667f5ad5e35847acd0e (patch)
treea7af4153b5f35657dce5621c4887f46daa843549 /vcl/unx/generic/fontmanager/fontconfig.cxx
parentaf8bf1b96ac1d994fd0376cc1047febf29c0c33f (diff)
avoid maybe-uninitialised in FontConfig
triggers inside the std::optional<PrintFont> with gcc 10.2.0 Change-Id: Id34e46ddfff447cb48b886003f04203979c30732 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117399 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/unx/generic/fontmanager/fontconfig.cxx')
-rw-r--r--vcl/unx/generic/fontmanager/fontconfig.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/vcl/unx/generic/fontmanager/fontconfig.cxx b/vcl/unx/generic/fontmanager/fontconfig.cxx
index 66f09ffc9102..184f000c0a43 100644
--- a/vcl/unx/generic/fontmanager/fontconfig.cxx
+++ b/vcl/unx/generic/fontmanager/fontconfig.cxx
@@ -17,6 +17,12 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#if defined __GNUC__ && !defined __clang_ && __GNUC__ >= 10
+// gcc 10.2.0 gets unhappy about one of the OString inside PrintFont at line 656
+// I have to turn it off here because the warning actually occurs inside rtl::OString
+#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
+#endif
+
#include <memory>
#include <string_view>