[Libreoffice-bugs] [Bug 126255] New: Relative links broken in Calc

bugzilla-daemon at bugs.documentfoundation.org bugzilla-daemon at bugs.documentfoundation.org
Sat Jul 6 18:22:34 UTC 2019


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

            Bug ID: 126255
           Summary: Relative links broken in Calc
           Product: LibreOffice
           Version: 6.4.0.0.alpha0+ Master
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: medium
         Component: Calc
          Assignee: libreoffice-bugs at lists.freedesktop.org
          Reporter: glogow at fbihome.de

Description:
I didn't test other components. The origin of this bug is the failing tinderbox
Win-x86_64_42.

In commit 3f7e8ddea89f ("Enable many more unit tests on all archs") I enabled
many more unit tests an all archs to verify if any arch specific #ifdefs are
still needed and fixed some fallout, Jenkins didn't catch in commit
a2c665e4dd73 ("WIN fix some unit tests more generally").

But there is one problem left: Win-x86_64_42 fails with

24952 NEXT    D:/lode/dev/core/sc/qa/unit/subsequent_export-test.cxx(3086) :
error : Assertion
24953         Test name: ScExportTest::testRelativePathsODS
24954 NEXT    assertion failed
24955         - Expression: aURL.startsWith("..")
24956         
24957         Failures !!!
24958         Run: 115   Failure total: 1   Failures: 1   Errors: 0

Thorsten thankfully added a SAL_DEBUG on that box, which shows:

> $ grep debug workdir/CppunitTest/sc_subsequent_export_test.test.log 
> debug:4516:2084:
> file:///D:/lode/dev/core/sc/qa/unit/data/ods/xlsx/databar.xlsx

So obviously the test fails. But it's actually broken on all architectures.

Just open the bug document of the unit test: sc/qa/unit/data/ods/fdo79305.ods.
It just contains a
link as

<text:a xlink:href="../xlsx/databar.xlsx"
xlink:type="simple">/devel/libo/libo1/sc/qa/unit/data/xlsx/databar.xlsx</text:a>

For me LO fails to open the link, because it resolves the wrong target.

origin: /libreoffice/sc/qa/unit/data/ods/fdo79305.ods
target: /libreoffice/sc/qa/unit/data/ods/xlsx/databar.xlsx
- an ods too much.

The unit test just tests CPPUNIT_ASSERT(aURL.startsWith("..")), which doesn't
make any sense. I would expect a correct absolute URL from LO for the relative
link inside the document, so it can be forwarded to whatever system "open link"
tool is used. Don't know how to test, if the contained link is absolute.

Maybe someone knows where to fix this bug. I really don't want to hide it again
using #ifndef _WIN32, but since this all includes those security link settings
and stuff, I would appreciate if someone else takes a stab at it.


Steps to Reproduce:
1. Open sc/qa/unit/data/ods/fdo79305.ods
2. Ctrl+Click the link


Actual Results:
Error message with wrong path.

Expected Results:
The linked document is opened.


Reproducible: Always


User Profile Reset: No



Additional Info:
Current master. Fails unit test on Windows. Manual test fails for the kde5
backend, but from the URL I guess it's broken on all archs.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20190706/0480ac3c/attachment-0001.html>


More information about the Libreoffice-bugs mailing list