https://bugs.documentfoundation.org/show_bug.cgi?id=145361

            Bug ID: 145361
           Summary: Cannot convert to XHTML document containing list with
                    line break
           Product: LibreOffice
           Version: 7.2.2.2 release
          Hardware: x86-64 (AMD64)
                OS: Linux (All)
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Writer
          Assignee: libreoffice-bugs@lists.freedesktop.org
          Reporter: m.n.polunin...@ya.ru

Created attachment 175972
  --> https://bugs.documentfoundation.org/attachment.cgi?id=175972&action=edit
Example exposing the error

Debian bullseye with LibreOffice 7.2.2 from backports. Trying to convert a
document containing list with line break leads to error

With unoconv:
```
# /usr/bin/python3 /usr/local/bin/unoconv -f  xhtml -o /tmp/test.xhtml
list-with-line-break.odt 
XSL Vendor: 'libxslt'
xmlXPathCompOpEval: function replace not found
XPath error : Unregistered function
runtime error: file
file:///usr/lib/libreoffice/share/xslt/export/common/body.xsl line 109 element
value-of
XPath evaluation returned no result.
unoconv: UnoException during export phase:
Unable to store document to file:///tmp/test.html (Error
(com.sun.star.io.IOException){ (com.sun.star.uno.Exception){ Message =
(string)"SfxBaseModel::impl_store <file:///tmp/test.html> failed: 0xc10(Error
Area:Io Class:Write Code:16) ./sfx2/source/doc/sfxbasemodel.cxx:3180
./sfx2/source/doc/sfxbasemodel.cxx:1762", Context =
(com.sun.star.uno.XInterface)0x0{} } })

Properties: ((com.sun.star.beans.PropertyValue){ Name = (string)"FilterName",
Handle = (long)0x0, Value = (any){ (string)"XHTML Writer File" }, State =
(com.sun.star.beans.PropertyState)DIRECT_VALUE },
(com.sun.star.beans.PropertyValue){ Name = (string)"OutputStream", Handle =
(long)0x0, Value = (any){ (com.sun.star.uno.XInterface)0x22c6a58{,
supportedInterfaces={com.sun.star.io.XOutputStream,com.sun.star.lang.XTypeProvider}}
}, State = (com.sun.star.beans.PropertyState)DIRECT_VALUE },
(com.sun.star.beans.PropertyValue){ Name = (string)"Overwrite", Handle =
(long)0x0, Value = (any){ (boolean)true }, State =
(com.sun.star.beans.PropertyState)DIRECT_VALUE })
```

With LibreOffice directly:
```
# libreoffice --convert-to "html:XHTML Writer File:UTF8" --outdir /tmp/
list-with-line-break.odt 
convert /tmp/list-with-line-break.odt -> /tmp/list-with-line-break.html using
filter : XHTML Writer File:UTF8
XSL Vendor: 'libxslt'
xmlXPathCompOpEval: function replace not found
XPath error : Unregistered function
runtime error: file
file:///usr/lib/libreoffice/share/xslt/export/common/body.xsl line 109 element
value-of
XPath evaluation returned no result.
Error: Please verify input parameters... (SfxBaseModel::impl_store
<file:///tmp/list-with-line-break.html> failed: 0xc10(Error Area:Io Class:Write
Code:16) ./sfx2/source/doc/sfxbasemodel.cxx:3180
./sfx2/source/doc/sfxbasemodel.cxx:1762)
```

If
https://git.libreoffice.org/core/+/3eb870f0843a00042ca7dd89837fbe0cc6f918c2%5E%21/#F0
is reverted, everything is fine:
```
# sed -i "s/replace(\$listIndent, ',', '.')/\$listIndent/"
/usr/lib/libreoffice/share/xslt/export/common/body.xsl
# /usr/bin/python3 /usr/local/bin/unoconv -f  xhtml -o /tmp/test.xhtml
list-with-line-break.odt 
XSL Vendor: 'libxslt'
# libreoffice --convert-to "html:XHTML Writer File:UTF8" --outdir /tmp/
list-with-line-break.odt 
convert /tmp/list-with-line-break.odt -> /tmp/list-with-line-break.html using
filter : XHTML Writer File:UTF8
XSL Vendor: 'libxslt'

```

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to