From 37bc6ca4bbdfa355440183f54e9fe35e8d23cae2 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 1 Mar 2024 08:54:29 +0200 Subject: fix ODR violation which causes a segfault in CppunitTest_hwpfilter_test_hwpfilter when building with --enable-mergelibs=more Change-Id: I4310060e28ee092bf7831d5dfd71e98ad3724bbe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/164177 Tested-by: Noel Grandin Reviewed-by: Noel Grandin --- hwpfilter/source/hwpfile.cxx | 4 ++-- hwpfilter/source/hwpfile.h | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hwpfilter/source/hwpfile.cxx b/hwpfilter/source/hwpfile.cxx index 637489aee04b..c186ad8609a4 100644 --- a/hwpfilter/source/hwpfile.cxx +++ b/hwpfilter/source/hwpfile.cxx @@ -566,13 +566,13 @@ void HWPFile::AddCharShape(std::shared_ptr const & cshape) void HWPFile::AddColumnInfo() { - columnlist.emplace_back(new ColumnInfo(m_nCurrentPage)); + columnlist.emplace_back(new HWPColumnInfo(m_nCurrentPage)); setMaxSettedPage(); } void HWPFile::SetColumnDef(const std::shared_ptr& rColdef) { - ColumnInfo *cinfo = columnlist.back().get(); + HWPColumnInfo *cinfo = columnlist.back().get(); if( cinfo->bIsSet ) return; cinfo->xColdef = rColdef; diff --git a/hwpfilter/source/hwpfile.h b/hwpfilter/source/hwpfile.h index 2c4d7e7bdc9e..126b7edf0fd8 100644 --- a/hwpfilter/source/hwpfile.h +++ b/hwpfilter/source/hwpfile.h @@ -68,11 +68,11 @@ class HWPStyle; class HWPPara; class HStream; -struct ColumnInfo{ +struct HWPColumnInfo{ int start_page; bool bIsSet; std::shared_ptr xColdef; - explicit ColumnInfo(int num){ + explicit HWPColumnInfo(int num){ start_page = num; bIsSet = false; } @@ -279,7 +279,7 @@ class DLLEXPORT HWPFile HWPInfo _hwpInfo; HWPFont _hwpFont; HWPStyle _hwpStyle; - std::vector> columnlist; + std::vector> columnlist; // paragraph list std::vector> plist; // keep paragraph's that failed to load until -- cgit