sc/source/ui/dbgui/PivotLayoutTreeListData.cxx | 6 +++--- vcl/source/control/calendar.cxx | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)
New commits: commit 0e77a73f2f8bcdaa36dd3c099405123c614b4770 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Tue Sep 6 14:07:45 2022 +0100 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Tue Sep 6 20:50:19 2022 +0200 cid#1500509 silence Out-of-bounds access Change-Id: I6f23c74f5e69610f1f3bf387467796f20ad4515a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139522 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/vcl/source/control/calendar.cxx b/vcl/source/control/calendar.cxx index 7554d0d99a08..0227db0c3e79 100644 --- a/vcl/source/control/calendar.cxx +++ b/vcl/source/control/calendar.cxx @@ -525,7 +525,7 @@ void Calendar::ImplDrawDate(vcl::RenderContext& rRenderContext, bool bOther, sal_Int32 nToday ) { Color const * pTextColor = nullptr; - const OUString& rDay = maDayTexts[nDay - 1]; + const OUString& rDay = maDayTexts[(nDay - 1) % std::size(maDayTexts)]; tools::Rectangle aDateRect(nX, nY, nX + mnDayWidth - 1, nY + mnDayHeight - 1); bool bSel = false; commit 37017c52ae3705e4d609e25a6722d588abe706c2 Author: Caolán McNamara <caol...@redhat.com> AuthorDate: Tue Sep 6 14:04:47 2022 +0100 Commit: Caolán McNamara <caol...@redhat.com> CommitDate: Tue Sep 6 20:50:02 2022 +0200 cid#1500538 Big parameter passed by value Change-Id: I4d432026d260c6bbda183a7849a83ed3f0a6a27c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/139521 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caol...@redhat.com> diff --git a/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx b/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx index 19992fc31831..7455613274c1 100644 --- a/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx +++ b/sc/source/ui/dbgui/PivotLayoutTreeListData.cxx @@ -94,13 +94,13 @@ IMPL_LINK_NOARG(ScPivotLayoutTreeListData, DoubleClickHdl, weld::TreeView&, bool mpFunctionDlg = pFactory->CreateScDPFunctionDlg(mxControl.get(), mpParent->GetLabelDataVector(), rCurrentLabelData, rCurrentFunctionData); - mpFunctionDlg->StartExecuteAsync([this, pCurrentItemValue, - rCurrentLabelData, nEntry](int nResult) mutable { + mpFunctionDlg->StartExecuteAsync([this, pCurrentItemValue, nEntry](int nResult) mutable { if (nResult == RET_OK) { ScPivotFuncData& rFunctionData = pCurrentItemValue->maFunctionData; rFunctionData.mnFuncMask = mpFunctionDlg->GetFuncMask(); - rCurrentLabelData.mnFuncMask = mpFunctionDlg->GetFuncMask(); + ScDPLabelData& rLabelData = mpParent->GetLabelData(rFunctionData.mnCol); + rLabelData.mnFuncMask = mpFunctionDlg->GetFuncMask(); rFunctionData.maFieldRef = mpFunctionDlg->GetFieldRef();