connectivity/source/parse/sqlbison.y                |    2 
 download.lst                                        |    4 -
 i18npool/source/localedata/data/eo.xml              |   18 +++---
 sw/qa/extras/ooxmlexport/data/longBookmarkName.fodt |   13 ++++
 sw/qa/extras/ooxmlexport/ooxmlexport18.cxx          |   31 +++++++++++
 sw/source/filter/ww8/docxattributeoutput.cxx        |   32 ++++++-----
 sw/source/filter/ww8/docxattributeoutput.hxx        |    2 
 sw/source/filter/ww8/wrtw8nds.cxx                   |   42 ---------------
 sw/source/filter/ww8/wrtww8.cxx                     |   49 +++++++++++++++++
 sw/source/filter/ww8/wrtww8.hxx                     |   10 ++-
 sw/source/filter/ww8/ww8atr.cxx                     |   14 ++---
 ucb/qa/cppunit/webdav/webdav_local_neon.cxx         |    8 +-
 vcl/qa/cppunit/pdfexport/data/wide_page1.fodt       |   40 ++++++++++++++
 vcl/qa/cppunit/pdfexport/pdfexport.cxx              |   56 ++++++++++++++++++++
 vcl/source/gdi/pdfwriter_impl.cxx                   |    8 --
 vcl/source/window/dockmgr.cxx                       |   16 +++++
 16 files changed, 257 insertions(+), 88 deletions(-)

New commits:
commit 32e03fd181a6852f00d464c9982e131726789a30
Author:     Michael Weghorn <m.wegh...@posteo.de>
AuthorDate: Tue Aug 1 09:44:56 2023 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:53 2023 +0200

    tdf#156100 tdf#156561 Revert to previous behavior for gtk popups
    
    In order to fix announcement of items in the popups with at
    least NVDA on Windows,
    
        commit dc0706cabfe39ddb6ea23d60ccfb756f2b9e6efb
        Date:   Wed Mar 15 17:00:27 2023 +0100
    
            tdf#140762 tdf#152671 Make dock win visible before showing popup
    
    made sure that the dock window is made visible before the
    popup is shown.
    
    That's problematic for the gtk implementations, though.
    
    On issue was addressed with
    
        commit 70642bb7afd2cee6f7ae6eff2936a35978bd0597
        Date:   Thu Apr 6 15:07:15 2023 +0100
    
            tdf#154470 try moving the Show of the client to after the float 
positioning
    
    , but there's still an issue for the RTL case (tdf#156100).
    
    To unbreak that while leaving the announcement with NVDA working
    properly, effectively revert to the original behavior for the
    gtk VCL plugins (which have their own implementation for popup
    handling) for now.
    
    Further analysis of the root causes is planned in the context of
    tdf#156561, so hopefully the code paths can be unified again in
    the future.
    (One issue is addressed by Change-Id 
I62ab32342ef67c770ced9f0d2be867dc9355bd4a,
    "tdf#156561 wina11y: Handle CHILD event", but that's not enough
    by itself.)
    
    Change-Id: Ie67bded6c380695866d5343dab9d3f563ada057a
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155125
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>
    Tested-by: Jenkins
    Reviewed-by: Michael Weghorn <m.wegh...@posteo.de>
    (cherry picked from commit 3bb762c53ea79f8915a1b8fa39f3f5f57aa68c84)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155148

diff --git a/vcl/source/window/dockmgr.cxx b/vcl/source/window/dockmgr.cxx
index d64f7cd8f208..87ca621f7f28 100644
--- a/vcl/source/window/dockmgr.cxx
+++ b/vcl/source/window/dockmgr.cxx
@@ -821,7 +821,21 @@ void ImplDockingWindowWrapper::StartPopupMode( ToolBox 
*pParentToolBox, FloatWin
     if( pParentToolBox->IsKeyEvent() )
         nFlags |= FloatWinPopupFlags::GrabFocus;
 
-    mpFloatWin->StartPopupMode( pParentToolBox, nFlags | 
FloatWinPopupFlags::MakeClientWindowVisibleBeforePopup);
+    // tdf#140762, tdf#152671, tdf#154470, tdf#156100: Without client window 
being visible
+    // before showing popup, at least NVDA on Windows does not announce items 
in the popup,
+    // so make the client window visible first. This is problematic for gtk 
VCL plugins though,
+    // so don't do it there and use different code paths for now.
+    // For further analysis of the root causes, there's tdf#156561.
+    const OUString sToolkit = Application::GetToolkitName();
+    if (sToolkit == "gtk3" || sToolkit == "gtk4")
+    {
+        mpFloatWin->StartPopupMode( pParentToolBox, nFlags);
+        GetWindow()->Show();
+    }
+    else
+    {
+        mpFloatWin->StartPopupMode( pParentToolBox, nFlags | 
FloatWinPopupFlags::MakeClientWindowVisibleBeforePopup);
+    }
 
     if( pParentToolBox->IsKeyEvent() )
     {
commit 00ac71208cd65dc7232a7a92e7f475685ea7dfe6
Author:     jucasaca <jucas...@gmail.com>
AuthorDate: Sat Jul 22 17:40:58 2023 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:53 2023 +0200

    fixing a typo in sqlbison.y
    
    schema_glement_list is not registered, son can't be used. 
schema_element_list is registered and defined and seems to be the correct
    
    Change-Id: I7661532707ce6ddb32b95629192e9ba9847f21df
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154766
    Reviewed-by: Julien Nabet <serval2...@yahoo.fr>
    Reviewed-by: Lionel Mamane <lio...@mamane.lu>
    Tested-by: Lionel Mamane <lio...@mamane.lu>
    (cherry picked from commit f8a312617838e8626e6e406791ad8d0aac368f23)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155171
    Tested-by: Jenkins
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>
    (cherry picked from commit 930c5dd29995a8711a62b2bd13a3d59833d8470d)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155182
    Reviewed-by: Michael Stahl <michael.st...@allotropia.de>

diff --git a/connectivity/source/parse/sqlbison.y 
b/connectivity/source/parse/sqlbison.y
index 6db0da9a4180..1740d88cbca6 100644
--- a/connectivity/source/parse/sqlbison.y
+++ b/connectivity/source/parse/sqlbison.y
@@ -323,7 +323,7 @@ schema:
 
 opt_schema_element_list:
                        {$$ = SQL_NEW_RULE;}
-       |       schema_glement_list
+       |       schema_element_list
        ;
 
 schema_element_list:
commit 21bcc6f9152223b4aedcbafd1f8ee445952c0af9
Author:     Mike Kaganski <mike.kagan...@collabora.com>
AuthorDate: Mon Jul 31 15:08:58 2023 +0300
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:49 2023 +0200

    tdf#156548: make truncated long bookmark name unique, and use it in 
hyperlinks
    
    Change-Id: I156359339ff8be85fe90cb6612eafdc6030c851f
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155092
    Tested-by: Jenkins
    Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155129
    Reviewed-by: Miklos Vajna <vmik...@collabora.com>

diff --git a/sw/qa/extras/ooxmlexport/data/longBookmarkName.fodt 
b/sw/qa/extras/ooxmlexport/data/longBookmarkName.fodt
new file mode 100644
index 000000000000..8b09760fcb6f
--- /dev/null
+++ b/sw/qa/extras/ooxmlexport/data/longBookmarkName.fodt
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<office:document 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
office:version="1.3" office:mimetype="application/vnd.oasis.opendocument.text">
+ <office:body>
+  <office:text>
+   <text:p><text:a xlink:type="simple" 
xlink:href="#A_bookmark_name_longer_than_forty_characters">This is a hyperlink 
to the first target paragraph below</text:a></text:p>
+   <text:p><text:a xlink:type="simple" 
xlink:href="#A_bookmark_name_longer_than_forty_characters2">This is a hyperlink 
to the second target paragraph below</text:a></text:p>
+   <text:p/>
+   <text:p><text:bookmark-start 
text:name="A_bookmark_name_longer_than_forty_characters"/>The first target 
paragraph with a bookmark with a very long name<text:bookmark-end 
text:name="A_bookmark_name_longer_than_forty_characters"/></text:p>
+   <text:p><text:bookmark-start 
text:name="A_bookmark_name_longer_than_forty_characters2"/>The second target 
paragraph with a bookmark with a very long name<text:bookmark-end 
text:name="A_bookmark_name_longer_than_forty_characters2"/></text:p>
+  </office:text>
+ </office:body>
+</office:document>
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx 
b/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx
index 1a3a551ffcfc..83a2c079fb55 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport18.cxx
@@ -629,6 +629,37 @@ CPPUNIT_TEST_FIXTURE(Test, testTdf150408_isLvl_RoundTrip)
     assertXPath(pXml, "/w:numbering/w:abstractNum/w:lvl[2]/w:isLgl");
 }
 
+CPPUNIT_TEST_FIXTURE(Test, testTdf156548)
+{
+    // Given a document using two bookmarks with similar names longer than 40 
characters
+    loadAndReload("longBookmarkName.fodt");
+
+    // After the export, the names must be no longer than 40 characters; they 
must be unique;
+    // and the hyperlinks must use the same names, to still point to the 
correct targets:
+
+    {
+        // 1st  paragraph - hyperlink to 4th paragraph
+        auto sURL = getProperty<OUString>(getRun(getParagraph(1), 1), 
"HyperLinkURL");
+        
CPPUNIT_ASSERT_EQUAL(OUString("#A_bookmark_name_longer_than_forty_charac"), 
sURL);
+        // 4th paragraph - a bookmark
+        auto xBookmark = 
getProperty<uno::Reference<container::XNamed>>(getRun(getParagraph(4), 1),
+                                                                        
"Bookmark");
+        
CPPUNIT_ASSERT_EQUAL(OUString("A_bookmark_name_longer_than_forty_charac"),
+                             xBookmark->getName());
+    }
+
+    {
+        // 2nd  paragraph - hyperlink to 5th paragraph
+        auto sURL = getProperty<OUString>(getRun(getParagraph(2), 1), 
"HyperLinkURL");
+        
CPPUNIT_ASSERT_EQUAL(OUString("#A_bookmark_name_longer_than_forty_chara1"), 
sURL);
+        // 5th paragraph - a bookmark
+        auto xBookmark = 
getProperty<uno::Reference<container::XNamed>>(getRun(getParagraph(5), 1),
+                                                                        
"Bookmark");
+        
CPPUNIT_ASSERT_EQUAL(OUString("A_bookmark_name_longer_than_forty_chara1"),
+                             xBookmark->getName());
+    }
+}
+
 CPPUNIT_PLUGIN_IMPLEMENT();
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx 
b/sw/source/filter/ww8/docxattributeoutput.cxx
index 93d61c157b06..3533397b2638 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -2112,11 +2112,11 @@ void DocxAttributeOutput::EndRun(const SwTextNode* 
pNode, sal_Int32 nPos, sal_In
     DoWriteBookmarkEndIfExist(nPos);
 }
 
-void DocxAttributeOutput::DoWriteBookmarkTagStart(std::u16string_view 
bookmarkName)
+void DocxAttributeOutput::DoWriteBookmarkTagStart(const OUString& bookmarkName)
 {
     m_pSerializer->singleElementNS(XML_w, XML_bookmarkStart,
         FSNS(XML_w, XML_id), OString::number(m_nNextBookmarkId),
-        FSNS(XML_w, XML_name), BookmarkToWord(bookmarkName));
+        FSNS(XML_w, XML_name), GetExport().BookmarkToWord(bookmarkName));
 }
 
 void DocxAttributeOutput::DoWriteBookmarkTagEnd(sal_Int32 const nId)
@@ -2172,7 +2172,7 @@ void 
DocxAttributeOutput::DoWriteBookmarkStartIfExist(sal_Int32 nRunPos)
     {
         DoWriteBookmarkTagStart(aIter->second);
         m_rOpenedBookmarksIds[aIter->second] = m_nNextBookmarkId;
-        m_sLastOpenedBookmark = 
OUStringToOString(BookmarkToWord(aIter->second), RTL_TEXTENCODING_UTF8);
+        m_sLastOpenedBookmark = 
OUStringToOString(GetExport().BookmarkToWord(aIter->second), 
RTL_TEXTENCODING_UTF8);
         m_nNextBookmarkId++;
     }
 }
@@ -2202,7 +2202,7 @@ void 
DocxAttributeOutput::DoWriteBookmarksStart(std::vector<OUString>& rStarts,
         bool bMove = false;
         bool bFrom = false;
         OString sBookmarkName = OUStringToOString(
-                BookmarkToWord(bookmarkName, &bMove, &bFrom), 
RTL_TEXTENCODING_UTF8);
+                GetExport().BookmarkToWord(bookmarkName, &bMove, &bFrom), 
RTL_TEXTENCODING_UTF8);
         if ( bMove )
         {
             // TODO: redline data of MoveBookmark is restored from the first 
redline of the bookmark
@@ -2234,7 +2234,7 @@ void 
DocxAttributeOutput::DoWriteBookmarksEnd(std::vector<OUString>& rEnds)
         {
             bool bMove = false;
             bool bFrom = false;
-            BookmarkToWord(bookmarkName, &bMove, &bFrom);
+            GetExport().BookmarkToWord(bookmarkName, &bMove, &bFrom);
             // Output the bookmark (including MoveBookmark of the tracked 
moving)
             if ( bMove )
                 DoWriteMoveRangeTagEnd(pPos->second, bFrom);
@@ -2262,12 +2262,12 @@ void 
DocxAttributeOutput::DoWritePermissionTagStart(std::u16string_view permissi
     {
         const std::size_t separatorIndex = permissionIdAndName.find(u':');
         assert(separatorIndex != std::u16string_view::npos);
-        const std::u16string_view permissionId   = 
permissionIdAndName.substr(0, separatorIndex);
-        const std::u16string_view permissionName = 
permissionIdAndName.substr(separatorIndex + 1);
+        const OUString permissionId(permissionIdAndName.substr(0, 
separatorIndex));
+        const OUString 
permissionName(permissionIdAndName.substr(separatorIndex + 1));
 
         m_pSerializer->singleElementNS(XML_w, XML_permStart,
-            FSNS(XML_w, XML_id), BookmarkToWord(permissionId),
-            FSNS(XML_w, XML_edGrp), BookmarkToWord(permissionName));
+            FSNS(XML_w, XML_id), GetExport().BookmarkToWord(permissionId),
+            FSNS(XML_w, XML_edGrp), 
GetExport().BookmarkToWord(permissionName));
     }
     else
     {
@@ -2276,12 +2276,12 @@ void 
DocxAttributeOutput::DoWritePermissionTagStart(std::u16string_view permissi
         assert(ok); (void)ok;
         const std::size_t separatorIndex = permissionIdAndName.find(u':');
         assert(separatorIndex != std::u16string_view::npos);
-        const std::u16string_view permissionId   = 
permissionIdAndName.substr(0, separatorIndex);
-        const std::u16string_view permissionName = 
permissionIdAndName.substr(separatorIndex + 1);
+        const OUString permissionId(permissionIdAndName.substr(0, 
separatorIndex));
+        const OUString 
permissionName(permissionIdAndName.substr(separatorIndex + 1));
 
         m_pSerializer->singleElementNS(XML_w, XML_permStart,
-            FSNS(XML_w, XML_id), BookmarkToWord(permissionId),
-            FSNS(XML_w, XML_ed), BookmarkToWord(permissionName));
+            FSNS(XML_w, XML_id), GetExport().BookmarkToWord(permissionId),
+            FSNS(XML_w, XML_ed), GetExport().BookmarkToWord(permissionName));
     }
 }
 
@@ -2303,10 +2303,10 @@ void 
DocxAttributeOutput::DoWritePermissionTagEnd(std::u16string_view permission
 
     const std::size_t separatorIndex = permissionIdAndName.find(u':');
     assert(separatorIndex != std::u16string_view::npos);
-    const std::u16string_view permissionId   = permissionIdAndName.substr(0, 
separatorIndex);
+    const OUString permissionId(permissionIdAndName.substr(0, separatorIndex));
 
     m_pSerializer->singleElementNS(XML_w, XML_permEnd,
-        FSNS(XML_w, XML_id), BookmarkToWord(permissionId));
+        FSNS(XML_w, XML_id), GetExport().BookmarkToWord(permissionId));
 }
 
 /// Write the start permissions
@@ -3795,6 +3795,8 @@ void DocxAttributeOutput::EndRuby(const SwTextNode& 
rNode, sal_Int32 nPos)
 bool DocxAttributeOutput::AnalyzeURL( const OUString& rUrl, const OUString& 
rTarget, OUString* pLinkURL, OUString* pMark )
 {
     bool bBookMarkOnly = AttributeOutputBase::AnalyzeURL( rUrl, rTarget, 
pLinkURL, pMark );
+    if (bBookMarkOnly)
+        *pMark = GetExport().BookmarkToWord(*pMark);
 
     if ( !pMark->isEmpty() )
     {
diff --git a/sw/source/filter/ww8/docxattributeoutput.hxx 
b/sw/source/filter/ww8/docxattributeoutput.hxx
index aaff43fc0683..9a7212b40ec1 100644
--- a/sw/source/filter/ww8/docxattributeoutput.hxx
+++ b/sw/source/filter/ww8/docxattributeoutput.hxx
@@ -753,7 +753,7 @@ protected:
 
 private:
 
-    void DoWriteBookmarkTagStart(std::u16string_view bookmarkName);
+    void DoWriteBookmarkTagStart(const OUString& bookmarkName);
     void DoWriteBookmarkTagEnd(sal_Int32 nId);
     void DoWriteMoveRangeTagStart(const OString & bookmarkName,
             bool bFrom, const SwRedlineData* pRedlineData);
diff --git a/sw/source/filter/ww8/wrtw8nds.cxx 
b/sw/source/filter/ww8/wrtw8nds.cxx
index 02eaf8be275d..c8d972a432eb 100644
--- a/sw/source/filter/ww8/wrtw8nds.cxx
+++ b/sw/source/filter/ww8/wrtw8nds.cxx
@@ -921,15 +921,6 @@ void WW8AttributeOutput::EndRuby(const SwTextNode& 
/*rNode*/, sal_Int32 /*nPos*/
     m_rWW8Export.OutputField( nullptr, ww::eEQ, OUString(), FieldFlags::End | 
FieldFlags::Close );
 }
 
-/*#i15387# Better ideas welcome*/
-static OUString &TruncateBookmark( OUString &rRet )
-{
-    if ( rRet.getLength() > 40 )
-        rRet = rRet.copy( 0, 40 );
-    OSL_ENSURE( rRet.getLength() <= 40, "Word cannot have bookmarks longer 
than 40 chars" );
-    return rRet;
-}
-
 OUString AttributeOutputBase::ConvertURL( const OUString& rUrl, bool 
bAbsoluteOut )
 {
     OUString sURL = rUrl;
@@ -1024,7 +1015,7 @@ bool WW8AttributeOutput::AnalyzeURL( const OUString& 
rUrl, const OUString& rTarg
     if (bBookMarkOnly)
     {
         sURL = FieldString(ww::eHYPERLINK);
-        *pMark = BookmarkToWord(*pMark);
+        *pMark = GetExport().BookmarkToWord(*pMark);
     }
     else
         sURL = FieldString( ww::eHYPERLINK ) + "\"" + sURL + "\"";
@@ -1205,35 +1196,6 @@ bool WW8AttributeOutput::EndURL(bool const)
     return true;
 }
 
-OUString BookmarkToWord(std::u16string_view rBookmark, bool* pIsMove, bool* 
pIsFrom)
-{
-    sal_Int32 nTrim = 0; // position to remove "__RefMoveRange" from bookmark 
names
-    if ( pIsMove )
-    {
-        static constexpr OUStringLiteral MoveFrom_Bookmark_NamePrefix = 
u"__RefMoveFrom__";
-        static constexpr OUStringLiteral MoveTo_Bookmark_NamePrefix = 
u"__RefMoveTo__";
-        if ( o3tl::starts_with(rBookmark, MoveFrom_Bookmark_NamePrefix) )
-        {
-            *pIsMove = true;
-            *pIsFrom = true;
-            nTrim = MoveFrom_Bookmark_NamePrefix.getLength();
-        }
-        else if ( o3tl::starts_with(rBookmark, MoveTo_Bookmark_NamePrefix) )
-        {
-            *pIsMove = true;
-            *pIsFrom = false;
-            nTrim = MoveTo_Bookmark_NamePrefix.getLength();
-        }
-    }
-    OUString sRet = INetURLObject::encode(
-        OUString(rBookmark.substr(nTrim)).replace(' ', '_'), // Spaces are 
prohibited in bookmark name
-        INetURLObject::PART_REL_SEGMENT_EXTRA,
-        INetURLObject::EncodeMechanism::All, RTL_TEXTENCODING_ASCII_US);
-    // Unicode letters are allowed
-    sRet = INetURLObject::decode(sRet, 
INetURLObject::DecodeMechanism::Unambiguous, RTL_TEXTENCODING_UTF8);
-    return TruncateBookmark(sRet);
-}
-
 OUString BookmarkToWriter(std::u16string_view rBookmark)
 {
     return INetURLObject::decode(rBookmark,
@@ -1243,7 +1205,7 @@ OUString BookmarkToWriter(std::u16string_view rBookmark)
 void SwWW8AttrIter::OutSwFormatRefMark(const SwFormatRefMark& rAttr)
 {
     if(m_rExport.HasRefToAttr(rAttr.GetRefName()))
-        m_rExport.AppendBookmark( MSWordExportBase::GetBookmarkName( 
REF_SETREFATTR,
+        m_rExport.AppendBookmark( m_rExport.GetBookmarkName( REF_SETREFATTR,
                                             &rAttr.GetRefName(), 0 ));
 }
 
diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx
index 1acea700955d..637286097968 100644
--- a/sw/source/filter/ww8/wrtww8.cxx
+++ b/sw/source/filter/ww8/wrtww8.cxx
@@ -4599,4 +4599,53 @@ const NfKeywordTable & 
MSWordExportBase::GetNfKeywordTable()
     return *m_pKeyMap;
 }
 
+OUString MSWordExportBase::BookmarkToWord(const OUString& rBookmark, bool* 
pIsMove, bool* pIsFrom)
+{
+    OUString sLookup = rBookmark;
+    if (pIsMove)
+    {
+        static constexpr OUStringLiteral MoveFrom_Bookmark_NamePrefix = 
u"__RefMoveFrom__";
+        static constexpr OUStringLiteral MoveTo_Bookmark_NamePrefix = 
u"__RefMoveTo__";
+        if (rBookmark.startsWith(MoveFrom_Bookmark_NamePrefix, &sLookup))
+        {
+            *pIsMove = true;
+            *pIsFrom = true;
+        }
+        else if (rBookmark.startsWith(MoveTo_Bookmark_NamePrefix, &sLookup))
+        {
+            *pIsMove = true;
+            *pIsFrom = false;
+        }
+    }
+    if (auto it = m_aBookmarkToWord.find(sLookup); it != 
m_aBookmarkToWord.end())
+        return it->second;
+
+    OUString sRet
+        = INetURLObject::encode(sLookup.replace(' ', '_'), // Spaces are 
prohibited in bookmark name
+                                INetURLObject::PART_REL_SEGMENT_EXTRA,
+                                INetURLObject::EncodeMechanism::All, 
RTL_TEXTENCODING_ASCII_US);
+    // Unicode letters are allowed
+    sRet = INetURLObject::decode(sRet, 
INetURLObject::DecodeMechanism::Unambiguous,
+                                 RTL_TEXTENCODING_UTF8);
+
+    /*#i15387#*/
+    // Word has 40 character limit for bookmarks: [MS-OE376] Part 4 Sect. 
2.13.6.2, bookmarkStart
+    if (sRet.getLength() > 40)
+    {
+        // Generate a unique bookmark name
+        sRet = sRet.copy(0, 40);
+        for (sal_uInt32 n = 1; n; ++n)
+        {
+            if (m_aWordBookmarks.find(sRet) == m_aWordBookmarks.end())
+                break;
+            auto num = OUString::number(n, 36);
+            sRet = sRet.subView(0, 40 - num.length) + num;
+        }
+    }
+
+    m_aBookmarkToWord[sLookup] = sRet;
+    m_aWordBookmarks.insert(sRet);
+    return sRet;
+}
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/source/filter/ww8/wrtww8.hxx b/sw/source/filter/ww8/wrtww8.hxx
index 16ffa22fab64..c7c22ea52320 100644
--- a/sw/source/filter/ww8/wrtww8.hxx
+++ b/sw/source/filter/ww8/wrtww8.hxx
@@ -50,6 +50,7 @@
 #include <map>
 #include <string_view>
 #include <vector>
+#include <unordered_map>
 
 
 class SvxBrushItem;
@@ -639,7 +640,7 @@ public:
     bool HasRefToFootOrEndnote(const bool isEndNote, const sal_uInt16 nSeqNo);
 
     /// Find the bookmark name.
-    static OUString GetBookmarkName( sal_uInt16 nTyp, const OUString* pName, 
sal_uInt16 nSeqNo );
+    OUString GetBookmarkName( sal_uInt16 nTyp, const OUString* pName, 
sal_uInt16 nSeqNo );
 
     /// Use OutputItem() on an item set according to the parameters.
     void OutputItemSet( const SfxItemSet& rSet, bool bPapFormat, bool 
bChpFormat, sal_uInt16 nScript, bool bExportParentItemSet );
@@ -927,9 +928,15 @@ public:
 
     static void CorrectTabStopInSet( SfxItemSet& rSet, sal_Int32 nAbsLeft );
 
+    OUString BookmarkToWord(const OUString& rBookmark, bool* pIsMove = nullptr,
+                            bool* pIsFrom = nullptr);
+
 private:
     MSWordExportBase( const MSWordExportBase& ) = delete;
     MSWordExportBase& operator=( const MSWordExportBase& ) = delete;
+
+    std::unordered_map<OUString, OUString> m_aBookmarkToWord;
+    o3tl::sorted_vector<OUString> m_aWordBookmarks;
 };
 
 /// The writer class that gets called for the WW8 filter.
@@ -1650,7 +1657,6 @@ public:
 sal_Int16 GetWordFirstLineOffset(const SwNumFormat &rFormat);
 // A bit of a bag on the side for now
 OUString FieldString(ww::eField eIndex);
-OUString BookmarkToWord(std::u16string_view rBookmark, bool* pIsMove = 
nullptr, bool* pIsFrom = nullptr);
 
 class WW8SHDLong
 {
diff --git a/sw/source/filter/ww8/ww8atr.cxx b/sw/source/filter/ww8/ww8atr.cxx
index cdf50ef2e70c..32bbe12fb5f2 100644
--- a/sw/source/filter/ww8/ww8atr.cxx
+++ b/sw/source/filter/ww8/ww8atr.cxx
@@ -1123,7 +1123,7 @@ void WW8AttributeOutput::StartRun( const SwRedlineData* 
pRedlineData, sal_Int32
     auto aRange = m_aBookmarksOfParagraphStart.equal_range(nPos);
     for( auto aIter = aRange.first; aIter != aRange.second; ++aIter)
     {
-        GetExport().AppendBookmark(BookmarkToWord(aIter->second));
+        GetExport().AppendBookmark(GetExport().BookmarkToWord(aIter->second));
     }
 }
 
@@ -1139,9 +1139,9 @@ void WW8AttributeOutput::EndRun( const SwTextNode* 
/*pNode*/, sal_Int32 nPos, sa
     for( auto aIter = aRange.first; aIter != aRange.second; ++aIter)
     {
         if(bLastRun)
-            
GetExport().AppendBookmarkEndWithCorrection(BookmarkToWord(aIter->second));
+            
GetExport().AppendBookmarkEndWithCorrection(GetExport().BookmarkToWord(aIter->second));
         else
-            GetExport().AppendBookmark(BookmarkToWord(aIter->second));
+            
GetExport().AppendBookmark(GetExport().BookmarkToWord(aIter->second));
     }
 }
 
@@ -3196,7 +3196,7 @@ void AttributeOutputBase::TextField( const SwFormatField& 
rField )
                     {
                         const OUString& aRefName(rRField.GetSetRefName());
                         sStr = FieldString(eField)
-                            + MSWordExportBase::GetBookmarkName(nSubType, 
&aRefName, 0);
+                               + GetExport().GetBookmarkName(nSubType, 
&aRefName, 0);
                     }
                     switch (pField->GetFormat())
                     {
@@ -3251,7 +3251,7 @@ void AttributeOutputBase::TextField( const SwFormatField& 
rField )
                                     eField = ww::eNONE;
                                     break;
                         }
-                        sStr = FieldString(eField) + 
MSWordExportBase::GetBookmarkName(nSubType, &sName, 0);
+                        sStr = FieldString(eField) + 
GetExport().GetBookmarkName(nSubType, &sName, 0);
                     }
                     switch (pField->GetFormat())
                     {
@@ -3284,7 +3284,7 @@ void AttributeOutputBase::TextField( const SwFormatField& 
rField )
                             break;
                     }
                     sStr = FieldString(eField)
-                        + MSWordExportBase::GetBookmarkName(nSubType, nullptr, 
rRField.GetSeqNo());
+                           + GetExport().GetBookmarkName(nSubType, nullptr, 
rRField.GetSeqNo());
                     break;
             }
 
@@ -3633,7 +3633,7 @@ void AttributeOutputBase::TextFootnote( const 
SwFormatFootnote& rFootnote )
     OUString sBkmkNm;
     if ( GetExport().HasRefToFootOrEndnote( rFootnote.IsEndNote(), 
rFootnote.GetTextFootnote()->GetSeqRefNo()))
     {
-        sBkmkNm = MSWordExportBase::GetBookmarkName( nTyp, nullptr,
+        sBkmkNm = GetExport().GetBookmarkName(nTyp, nullptr,
                                     rFootnote.GetTextFootnote()->GetSeqRefNo() 
);
         GetExport().AppendBookmark( sBkmkNm );
     }
commit 52d9d30371247f7d613dd9d1fd5f0c4fdf94682a
Author:     Stephan Bergmann <sberg...@redhat.com>
AuthorDate: Mon Jul 31 21:34:49 2023 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:09 2023 +0200

    Update to curl-8.2.1.tar.xz
    
    ...obtained from <https://curl.se/download/curl-8.2.1.tar.xz>
    
    Change-Id: I7260f79e2f72501869ff58c77f0d9dfa3ebdece1
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155116
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sberg...@redhat.com>
    (cherry picked from commit 85c07891ad9424661d8e1adb8e93364e3964ce34)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155133
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/download.lst b/download.lst
index 2ec54fd810de..68cd2fda89bf 100644
--- a/download.lst
+++ b/download.lst
@@ -75,8 +75,8 @@ CPPUNIT_TARBALL := cppunit-1.15.1.tar.gz
 # three static lines
 # so that git cherry-pick
 # will not run into conflicts
-CURL_SHA256SUM := 
31b1118eb8bfd43cd95d9a3f146f814ff874f6ed3999b29d94f4d1e7dbac5ef6
-CURL_TARBALL := curl-8.1.2.tar.xz
+CURL_SHA256SUM := 
dd322f6bd0a20e6cebdfd388f69e98c3d183bed792cf4713c8a7ef498cba4894
+CURL_TARBALL := curl-8.2.1.tar.xz
 # three static lines
 # so that git cherry-pick
 # will not run into conflicts
commit f2f3ad49db50b69dcd5c31b367a6d9ce29c24032
Author:     Mike Kaganski <mike.kagan...@collabora.com>
AuthorDate: Fri Jul 28 17:55:17 2023 +0300
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:09 2023 +0200

    tdf#156528: Fix handling PDF page scaling factor after large pages
    
    The map mode wasn't set when current page's user unit was 1, which meant
    that it used the unchanged value from the previous page, where it could
    be different.
    
    Change-Id: Id1f1515dceac25cddc12081a86fabf8b32d633f0
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155025
    Tested-by: Mike Kaganski <mike.kagan...@collabora.com>
    Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com>
    (cherry picked from commit 0b6fc1fdcc67cc6e13ca3c0e4c81742a43488ed6)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155141
    Reviewed-by: خالد حسني <kha...@libreoffice.org>
    Tested-by: Jenkins

diff --git a/vcl/qa/cppunit/pdfexport/data/wide_page1.fodt 
b/vcl/qa/cppunit/pdfexport/data/wide_page1.fodt
new file mode 100644
index 000000000000..9e7390a8e22a
--- /dev/null
+++ b/vcl/qa/cppunit/pdfexport/data/wide_page1.fodt
@@ -0,0 +1,40 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<office:document 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:ooow="http://openoffice.org/200
 4/writer" xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:xforms="http://www.w3.org/2002/xforms"; 
xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" 
xmlns:script="urn:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:formx="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0"
 xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; xmlns
 :css3t="http://www.w3.org/TR/css3-text/"; 
xmlns:officeooo="http://openoffice.org/2009/office"; office:version="1.3" 
office:mimetype="application/vnd.oasis.opendocument.text">
+ <office:styles>
+ </office:styles>
+ <office:automatic-styles>
+  <style:style style:name="P1" style:family="paragraph" 
style:master-page-name="very_5f_wide"/>
+  <style:style style:name="P2" style:family="paragraph" 
style:master-page-name="Standard">
+   <style:paragraph-properties fo:break-before="page"/>
+  </style:style>
+  <style:style style:name="gr1" style:family="graphic">
+   <style:graphic-properties draw:fill="none" 
draw:textarea-horizontal-align="justify" draw:textarea-vertical-align="middle" 
draw:auto-grow-height="false" fo:min-height="257mm" fo:min-width="170mm" 
loext:decorative="false" style:run-through="foreground" 
style:wrap="run-through" style:number-wrapped-paragraphs="no-limit" 
style:vertical-pos="from-top" style:vertical-rel="page-content" 
style:horizontal-pos="from-left" style:horizontal-rel="page-content"/>
+  </style:style>
+  <style:style style:name="gr2" style:family="graphic">
+   <style:graphic-properties draw:fill="none" 
draw:textarea-horizontal-align="justify" draw:textarea-vertical-align="middle" 
draw:auto-grow-height="false" fo:min-height="170mm" fo:min-width="5060mm" 
loext:decorative="false" style:run-through="foreground" 
style:wrap="run-through" style:number-wrapped-paragraphs="no-limit" 
style:vertical-pos="from-top" style:vertical-rel="page-content" 
style:horizontal-pos="from-left" style:horizontal-rel="page-content"/>
+  </style:style>
+  <style:page-layout style:name="pm1">
+   <style:page-layout-properties fo:page-width="210mm" fo:page-height="297mm" 
style:print-orientation="portrait" fo:margin-top="20mm" fo:margin-bottom="20mm" 
fo:margin-left="20mm" fo:margin-right="20mm"/>
+  </style:page-layout>
+  <style:page-layout style:name="pm2">
+   <style:page-layout-properties fo:page-width="5100mm" fo:page-height="210mm" 
style:print-orientation="landscape" fo:margin-top="20mm" 
fo:margin-bottom="20mm" fo:margin-left="20mm" fo:margin-right="20mm"/>
+  </style:page-layout>
+ </office:automatic-styles>
+ <office:master-styles>
+  <style:master-page style:name="Standard" style:page-layout-name="pm1"/>
+  <style:master-page style:name="very_5f_wide" style:display-name="very_wide" 
style:page-layout-name="pm2"/>
+ </office:master-styles>
+ <office:body>
+  <office:text>
+   <text:p text:style-name="P1"><draw:custom-shape 
text:anchor-type="paragraph" draw:z-index="0" draw:name="Shape 1" 
draw:style-name="gr2" svg:width="5060mm" svg:height="170mm" svg:x="0mm" 
svg:y="0mm">
+     <text:p/>
+     <draw:enhanced-geometry svg:viewBox="0 0 21600 21600" 
draw:type="rectangle" draw:enhanced-path="M 0 0 L 21600 0 21600 21600 0 21600 0 
0 Z N"/>
+    </draw:custom-shape></text:p>
+   <text:p text:style-name="P2"><draw:custom-shape 
text:anchor-type="paragraph" draw:z-index="1" draw:name="Shape 2" 
draw:style-name="gr1" svg:width="170mm" svg:height="257mm" svg:x="0mm" 
svg:y="0mm">
+     <text:p/>
+     <draw:enhanced-geometry svg:viewBox="0 0 21600 21600" 
draw:type="rectangle" draw:enhanced-path="M 0 0 L 21600 0 21600 21600 0 21600 0 
0 Z N"/>
+    </draw:custom-shape></text:p>
+  </office:text>
+ </office:body>
+</office:document>
\ No newline at end of file
diff --git a/vcl/qa/cppunit/pdfexport/pdfexport.cxx 
b/vcl/qa/cppunit/pdfexport/pdfexport.cxx
index 95667732c549..bf35818056df 100644
--- a/vcl/qa/cppunit/pdfexport/pdfexport.cxx
+++ b/vcl/qa/cppunit/pdfexport/pdfexport.cxx
@@ -4735,6 +4735,62 @@ CPPUNIT_TEST_FIXTURE(PdfExportTest, testTdf48707_2)
     }
 }
 
+CPPUNIT_TEST_FIXTURE(PdfExportTest, testTdf156528)
+{
+    aMediaDescriptor["FilterName"] <<= OUString("writer_pdf_Export");
+    saveAsPDF(u"wide_page1.fodt");
+    std::unique_ptr<vcl::pdf::PDFiumDocument> pPdfDocument = parsePDFExport();
+
+    // The document has two pages
+    CPPUNIT_ASSERT_EQUAL(2, pPdfDocument->getPageCount());
+
+    // 1st page (5100 mm width x 210 mm high, UserUnit = 2)
+    auto pPdfPage = pPdfDocument->openPage(0);
+    CPPUNIT_ASSERT(pPdfPage);
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(5100.0 / 2, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 pPdfPage->getWidth(), 1);
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(210.0 / 2, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 pPdfPage->getHeight(), 1);
+
+    // 1 object (rectangle 5060 mm width x 170 mm high, UserUnit = 2)
+    CPPUNIT_ASSERT_EQUAL(1, pPdfPage->getObjectCount());
+    auto pRect = pPdfPage->getObject(0);
+    CPPUNIT_ASSERT(pRect);
+    CPPUNIT_ASSERT_EQUAL(vcl::pdf::PDFPageObjectType::Path, pRect->getType());
+    auto bounds = pRect->getBounds();
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(5060.0 / 2, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 bounds.getWidth(), 1);
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(170.0 / 2, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 bounds.getHeight(), 1);
+
+    // 2nd page (210 mm width x 297 mm high, UserUnit = 1)
+    pPdfPage = pPdfDocument->openPage(1);
+    CPPUNIT_ASSERT(pPdfPage);
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(210.0, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 pPdfPage->getWidth(), 1);
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(297.0, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 pPdfPage->getHeight(), 1);
+
+    // 1 object (rectangle 170 mm width x 257 mm high, UserUnit = 1)
+    CPPUNIT_ASSERT_EQUAL(1, pPdfPage->getObjectCount());
+    pRect = pPdfPage->getObject(0);
+    CPPUNIT_ASSERT(pRect);
+    CPPUNIT_ASSERT_EQUAL(vcl::pdf::PDFPageObjectType::Path, pRect->getType());
+    bounds = pRect->getBounds();
+    // Without the fix, this would fail with
+    // - Expected: 481.889763779528
+    // - Actual  : 241.925001144409
+    // - Delta   : 1
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(170.0, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 bounds.getWidth(), 1);
+    //
+    // - Expected: 728.503937007874
+    // - Actual  : 365.25
+    // - Delta   : 1
+    CPPUNIT_ASSERT_DOUBLES_EQUAL(o3tl::convert(257.0, o3tl::Length::mm, 
o3tl::Length::pt),
+                                 bounds.getHeight(), 1);
+}
+
 } // end anonymous namespace
 
 CPPUNIT_PLUGIN_IMPLEMENT();
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx 
b/vcl/source/gdi/pdfwriter_impl.cxx
index 2e79a3289ec3..d9e94863e3c5 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -1692,12 +1692,8 @@ void PDFWriterImpl::newPage( double nPageWidth, double 
nPageHeight, PDFWriter::O
     m_nCurrentPage = m_aPages.size();
     m_aPages.emplace_back(this, nPageWidth, nPageHeight, eOrientation );
 
-    sal_Int32 nUserUnit = m_aPages.back().m_nUserUnit;
-    if (nUserUnit > 1)
-    {
-        m_aMapMode = MapMode(MapUnit::MapPoint, Point(), Fraction(nUserUnit, 
pointToPixel(1)),
-                             Fraction(nUserUnit, pointToPixel(1)));
-    }
+    const Fraction frac(m_aPages.back().m_nUserUnit, pointToPixel(1));
+    m_aMapMode = MapMode(MapUnit::MapPoint, Point(), frac, frac);
 
     m_aPages.back().beginStream();
 
commit 0a5ae7b86e90e97be526fec7bd6cc958250ef5c5
Author:     Eike Rathke <er...@redhat.com>
AuthorDate: Mon Jul 31 20:13:02 2023 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:09 2023 +0200

    Correct Esperanto {eo} group separator formats wrong since initial 2005 
commit
    
    Instead of # ##0,00 and similar it used # #0,00 that probably went
    unnoticed since ever because it generates an expected display
    string using the group separator at the right position; editing
    such format yielded the format code ##0,00 with the group
    separator flag set.
    
    Change-Id: Id6ebb533f43a49a9aea1dd9ba87230e5d59901ea
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155114
    Reviewed-by: Eike Rathke <er...@redhat.com>
    Tested-by: Jenkins
    (cherry picked from commit 613c3524eb798392040c691d5c0e17fac0b654b8)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155048
    Reviewed-by: Adolfo Jayme Barrientos <fit...@ubuntu.com>
    (cherry picked from commit b6ed7c7be2a94777ee9b1c4a5ddf77e3f5343efe)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155142
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/i18npool/source/localedata/data/eo.xml 
b/i18npool/source/localedata/data/eo.xml
index 6cef3274b54d..ba718f92f4a1 100644
--- a/i18npool/source/localedata/data/eo.xml
+++ b/i18npool/source/localedata/data/eo.xml
@@ -157,31 +157,31 @@
       <FormatCode>0,00</FormatCode>
     </FormatElement>
     <FormatElement msgid="FixedFormatskey4" default="false" type="short" 
usage="FIXED_NUMBER"  formatindex="3">
-      <FormatCode># #0</FormatCode>
+      <FormatCode># ##0</FormatCode>
     </FormatElement>
     <FormatElement msgid="FixedFormatskey5" default="false" type="medium" 
usage="FIXED_NUMBER"  formatindex="4">
-      <FormatCode># #0,00</FormatCode>
+      <FormatCode># ##0,00</FormatCode>
     </FormatElement>
     <FormatElement msgid="FixedFormatskey6" default="false" type="medium" 
usage="FIXED_NUMBER"  formatindex="5">
-      <FormatCode># ##,00</FormatCode>
+      <FormatCode># ###,00</FormatCode>
     </FormatElement>
     <FormatElement msgid="CurrencyFormatskey1" default="true" type="short" 
usage="CURRENCY"  formatindex="12">
-      <FormatCode># #0 [CURRENCY];-# #0 [CURRENCY]</FormatCode>
+      <FormatCode># ##0 [CURRENCY];-# ##0 [CURRENCY]</FormatCode>
     </FormatElement>
     <FormatElement msgid="CurrencyFormatskey2" default="false" type="medium" 
usage="CURRENCY"  formatindex="13">
-      <FormatCode># #0,00 [CURRENCY];-# #0,00 [CURRENCY]</FormatCode>
+      <FormatCode># ##0,00 [CURRENCY];-# ##0,00 [CURRENCY]</FormatCode>
     </FormatElement>
     <FormatElement msgid="CurrencyFormatskey3" default="false" type="medium" 
usage="CURRENCY"  formatindex="14">
-      <FormatCode># #0 [CURRENCY];[RED]-# #0 [CURRENCY]</FormatCode>
+      <FormatCode># ##0 [CURRENCY];[RED]-# ##0 [CURRENCY]</FormatCode>
     </FormatElement>
     <FormatElement msgid="CurrencyFormatskey4" default="true" type="medium" 
usage="CURRENCY"  formatindex="15">
-      <FormatCode># #0,00 [CURRENCY];[RED]-# #0,00 [CURRENCY]</FormatCode>
+      <FormatCode># ##0,00 [CURRENCY];[RED]-# ##0,00 [CURRENCY]</FormatCode>
     </FormatElement>
     <FormatElement msgid="CurrencyFormatskey5" default="false" type="medium" 
usage="CURRENCY"  formatindex="16">
-      <FormatCode># #0,00 CCC</FormatCode>
+      <FormatCode># ##0,00 CCC</FormatCode>
     </FormatElement>
     <FormatElement msgid="CurrencyFormatskey6" default="false" type="medium" 
usage="CURRENCY"  formatindex="17">
-      <FormatCode># #0,-- [CURRENCY];[RED]-# #0,-- [CURRENCY]</FormatCode>
+      <FormatCode># ##0,-- [CURRENCY];[RED]-# ##0,-- [CURRENCY]</FormatCode>
     </FormatElement>
     <FormatElement msgid="PercentFormatskey1" default="true" type="short" 
usage="PERCENT_NUMBER"  formatindex="8">
       <FormatCode>0%</FormatCode>
commit b69b5ff79bd47ca66e4c1a9569e2f1daba013a9f
Author:     Stephan Bergmann <sberg...@redhat.com>
AuthorDate: Mon Jul 31 17:09:32 2023 +0200
Commit:     Andras Timar <andras.ti...@collabora.com>
CommitDate: Wed Aug 2 17:47:09 2023 +0200

    Adapt test code to cURL 8.2.0
    
    ...for which CppunitTest_ucb_webdav_core would fail with
    
    > ucb/qa/cppunit/webdav/webdav_local_neon.cxx:60:(anonymous 
namespace)::webdav_local_test::WebdavUriTest
    > equality assertion failed
    > - Expected: ?query#fragment
    > - Actual  : /?query#fragment
    
    and
    
    > ucb/qa/cppunit/webdav/webdav_local_neon.cxx:89:(anonymous 
namespace)::webdav_local_test::WebdavUriTest2
    > equality assertion failed
    > - Expected: ?query
    > - Actual  : /?query
    
    because of
    
<https://github.com/bch/curl/commit/5752e71080cb3aafa8b24c3261419345b832bc92>
    "urlapi: have *set(PATH) prepend a slash if one is missing".
    
    All that test code had been added with 
b03e070420606d407df2ec5e9dfa7043ecc46177
    "ucb: webdav-curl: fix CurlUri::CloneWithRelativeRefPathAbsolute()", and it
    looks harmless for our use cases that cURL started to behave differently 
there
    now.  So instead of accepting either of the outcomes depending on what cURL
    version is being used, just change the test code to not leave out the
    path-absolute in the calls to CloneWithRelativeRefPathAbsolute (which is
    documented in ucb/source/ucp/webdav-curl/CurlUri.hxx to take
    
    >     /// @param matches: relative-ref = path-absolute [ "?" query ] [ "#" 
fragment ]
    
    and path-absolute cannot be empty as per RFC 3986 "Uniform Resource 
Identifier
    (URI): Generic Syntax").
    
    Change-Id: If07a28598dfa047ebe89d8bcda19e8fcaa36aed0
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155099
    Reviewed-by: Michael Stahl <michael.st...@allotropia.de>
    Tested-by: Jenkins
    Reviewed-by: Stephan Bergmann <sberg...@redhat.com>
    Signed-off-by: Xisco Fauli <xiscofa...@libreoffice.org>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155134

diff --git a/ucb/qa/cppunit/webdav/webdav_local_neon.cxx 
b/ucb/qa/cppunit/webdav/webdav_local_neon.cxx
index bde7652b9ffa..a457bc6d2b28 100644
--- a/ucb/qa/cppunit/webdav/webdav_local_neon.cxx
+++ b/ucb/qa/cppunit/webdav/webdav_local_neon.cxx
@@ -52,12 +52,12 @@ namespace
         CPPUNIT_ASSERT_EQUAL( OUString("/foo/bar"), 
uri2.GetRelativeReference() );
         CPPUNIT_ASSERT_EQUAL( 
OUString("http://user%40anothern...@server.biz:8040/foo/bar";), uri2.GetURI() );
 
-        CurlUri 
uri3(aURI.CloneWithRelativeRefPathAbsolute(u"?query#fragment"));
+        CurlUri 
uri3(aURI.CloneWithRelativeRefPathAbsolute(u"/?query#fragment"));
         CPPUNIT_ASSERT_EQUAL( OUString("http"), uri3.GetScheme() );
         CPPUNIT_ASSERT_EQUAL( OUString("server.biz"), uri3.GetHost() );
         CPPUNIT_ASSERT_EQUAL( OUString("user%40anothername"), uri3.GetUser() );
         CPPUNIT_ASSERT_EQUAL( sal_uInt16(8040), uri3.GetPort() );
-        CPPUNIT_ASSERT_EQUAL( OUString("?query#fragment"), 
uri3.GetRelativeReference() );
+        CPPUNIT_ASSERT_EQUAL( OUString("/?query#fragment"), 
uri3.GetRelativeReference() );
         CPPUNIT_ASSERT_EQUAL( 
OUString("http://user%40anothern...@server.biz:8040/?query#fragment";), 
uri3.GetURI() );
     }
 
@@ -80,13 +80,13 @@ namespace
         CPPUNIT_ASSERT_EQUAL( OUString("/foo/bar"), 
uri2.GetRelativeReference() );
         CPPUNIT_ASSERT_EQUAL( 
OUString("https://foo:b...@server.biz:8040/foo/bar";), uri2.GetURI() );
 
-        CurlUri uri3(aURI.CloneWithRelativeRefPathAbsolute(u"?query"));
+        CurlUri uri3(aURI.CloneWithRelativeRefPathAbsolute(u"/?query"));
         CPPUNIT_ASSERT_EQUAL( OUString("https"), uri3.GetScheme() );
         CPPUNIT_ASSERT_EQUAL( OUString("server.biz"), uri3.GetHost() );
         CPPUNIT_ASSERT_EQUAL( OUString("foo"), uri3.GetUser() );
         CPPUNIT_ASSERT_EQUAL( OUString("bar"), uri3.GetPassword() );
         CPPUNIT_ASSERT_EQUAL( sal_uInt16(8040), uri3.GetPort() );
-        CPPUNIT_ASSERT_EQUAL( OUString("?query"), uri3.GetRelativeReference() 
);
+        CPPUNIT_ASSERT_EQUAL( OUString("/?query"), uri3.GetRelativeReference() 
);
         CPPUNIT_ASSERT_EQUAL( 
OUString("https://foo:b...@server.biz:8040/?query";), uri3.GetURI() );
     }
 

Reply via email to