sal/osl/unx/pipe.cxx | 5 +---- sw/source/uibase/dochdl/gloshdl.cxx | 7 ++++--- 2 files changed, 5 insertions(+), 7 deletions(-)
New commits: commit 88fe9c4903f65593785b3895e43e4e3ee17ba2f3 Author: Caolán McNamara <caolan.mcnam...@collabora.com> AuthorDate: Sat Nov 2 20:12:29 2024 +0000 Commit: Caolán McNamara <caolan.mcnam...@collabora.com> CommitDate: Mon Nov 4 09:39:04 2024 +0100 Drop requirement that there is internal/shared autotext. A user's autotext was not examined unless there existed some internal/shared autotext. There seems to be no particular reason for that, except that internal/shared autotext happens to generally be available. Change-Id: I43a9fe5916d3a0895b175db52758104cc7fd65b3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175959 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com> diff --git a/sw/source/uibase/dochdl/gloshdl.cxx b/sw/source/uibase/dochdl/gloshdl.cxx index 2e52e68b95d4..7706bf899b80 100644 --- a/sw/source/uibase/dochdl/gloshdl.cxx +++ b/sw/source/uibase/dochdl/gloshdl.cxx @@ -383,7 +383,7 @@ bool SwGlossaryHdl::ExpandGlossary(weld::Window* pParent) if(m_pWrtShell->IsSelection()) aShortName = m_pWrtShell->GetSelText(); } - return pGlossary && Expand(pParent, aShortName, &m_rStatGlossaries, std::move(pGlossary)); + return Expand(pParent, aShortName, &m_rStatGlossaries, std::move(pGlossary)); } bool SwGlossaryHdl::Expand(weld::Window* pParent, const OUString& rShortName, @@ -396,7 +396,8 @@ bool SwGlossaryHdl::Expand(weld::Window* pParent, const OUString& rShortName, // search for text block // - don't prefer current group depending on configuration setting const SvxAutoCorrCfg& rCfg = SvxAutoCorrCfg::Get(); - sal_uInt16 nFound = !rCfg.IsSearchInAllCategories() ? pGlossary->GetIndex( aShortName ) : USHRT_MAX; + sal_uInt16 nFound = (!rCfg.IsSearchInAllCategories() && pGlossary) ? + pGlossary->GetIndex( aShortName ) : USHRT_MAX; // if not found then search in all groups if (nFound == USHRT_MAX) { @@ -407,7 +408,7 @@ bool SwGlossaryHdl::Expand(weld::Window* pParent, const OUString& rShortName, { // get group name with path-extension const OUString sGroupName = pGlossaryList->GetGroupName(i); - if(sGroupName == pGlossary->GetName()) + if (pGlossary && sGroupName == pGlossary->GetName()) continue; const sal_uInt16 nBlockCount = pGlossaryList->GetBlockCount(i); if(nBlockCount) commit 910ae381bd97df03eaeb0822f56c1f8cec7ac594 Author: Caolán McNamara <caolan.mcnam...@collabora.com> AuthorDate: Wed Aug 21 21:41:45 2024 +0100 Commit: Caolán McNamara <caolan.mcnam...@collabora.com> CommitDate: Mon Nov 4 09:38:52 2024 +0100 merge creating variable and assigning it Change-Id: I1c8533f5adf5ab1db88dc279fc8e9a21c38c66bb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175976 Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com> Tested-by: Jenkins diff --git a/sal/osl/unx/pipe.cxx b/sal/osl/unx/pipe.cxx index c485f8da27f3..b683e17b2623 100644 --- a/sal/osl/unx/pipe.cxx +++ b/sal/osl/unx/pipe.cxx @@ -478,10 +478,7 @@ sal_Int32 SAL_CALL osl_writePipe(oslPipe pPipe, const void *pBuffer, sal_Int32 n SAL_WARN_IF(!pPipe, "sal.osl.pipe", "osl_writePipe: invalid pipe"); // osl_sendPipe detects invalid pipe while (BytesToSend > 0) { - sal_Int32 RetVal; - - RetVal= osl_sendPipe(pPipe, pBuffer, BytesToSend); - + sal_Int32 RetVal = osl_sendPipe(pPipe, pBuffer, BytesToSend); /* error occurred? */ if (RetVal <= 0) break;