Bug 116243 - App crash after click in Header or Footer on Writer
Summary: App crash after click in Header or Footer on Writer
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Android Viewer (show other bugs)
Version:
(earliest affected)
6.1.0.0.alpha0+
Hardware: All Android
: medium normal
Assignee: Michael Weghorn
URL:
Whiteboard: target:7.0.0
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-06 16:30 UTC by Charlene
Modified: 2020-04-08 07:19 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
File with header and footer (28.94 KB, application/vnd.oasis.opendocument.text)
2018-03-08 08:26 UTC, Wiildy
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Charlene 2018-03-06 16:30:18 UTC
Description:
I have a .odt with an Header/Footer, the openning of this document don't crash but if I click in the header or the footer, the application crash.

Here my Logcat after crash:
9342-10403/org.example.libreoffice E/libo:sal/osl/unx/file: failed to open /assets//config/soffice.cfg/modules/swriter/ui/headerfootermenu.ui

9342-10393/org.example.libreoffice I/stderr: terminate called after throwing an instance of 'com::sun::star::container::NoSuchElementException'

9342-10403/org.example.libreoffice I/LibreOffice/androidinst: SalAbort: 'Unknown application error'

Thanks for your help

Steps to Reproduce:
1. Open document with header/footer
2. Click on header or on footer
3. crash

Actual Results:  
crash

Expected Results:
doesn't crash


Reproducible: Always


User Profile Reset: No



Additional Info:


User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.186 Safari/537.36
Comment 1 raal 2018-03-07 18:16:04 UTC
Hello,

Thank you for filing the bug. Please send us a sample document, as this makes
it easier for us to verify the bug. 
I have set the bug's status to 'NEEDINFO', so please do change it back to
'UNCONFIRMED' once you have attached a document.
(Please note that the attachment will be public, remove any sensitive
information before attaching it.)
How can I eliminate confidential data from a sample document?
https://wiki.documentfoundation.org/QA/FAQ#How_can_I_eliminate_confidential_data_from_a_sample_document.3F
Thank you
Comment 2 Wiildy 2018-03-08 08:26:53 UTC
Created attachment 140463 [details]
File with header and footer
Comment 3 Charlene 2018-03-21 08:18:44 UTC
Thank you Wildy for your attachment !

Does anyone have a solution to offer?

Thanks for your job
Comment 4 raal 2018-04-07 16:30:01 UTC
Confirm. Android 5; Version: 6.1.0.0.alpha0+
Build ID: d36f7c5bd211
Comment 5 Gilles Dubois 2018-04-09 15:26:54 UTC
Hi,

I managed to hard fix the problem. My solution is not acceptable because it's not generic but i think it can help you :)

The problem that cause the crash is :
E/libo:sal/osl/unx/file: failed to open /assets//config/soffice.cfg/modules/swriter/ui/headerfootermenu.ui

As you can see in the printed path there is a folder missing in the path.
Tha path should be : "/assets/share/config/soffice.cfg/modules/swriter/ui/headerfootermenu.ui"

The file where the crash occurs is "sal/osl/unx/file.cxx" It would be nice to add more check in the ANDROID part of the path. (think of path integrity check)

I hard fixed the path in this file for testing purposes and it's working I can now edit and click on the header/footer.

I am using the experimental for 3 months and a lot of crashes I encounter are due to this behavior. This bug is present in a lot an area of the app, you should consider making it as a high priority.

Regards,
Gilles Dubois.
Comment 6 QA Administrators 2019-04-10 02:59:07 UTC Comment hidden (obsolete)
Comment 7 Michael Weghorn 2019-12-13 10:16:29 UTC
Is this still reproducible with a current daily build?

I think cloph recently mentioned having fixed something that sounded related (some problem with including various .ui files).
Comment 8 Michael Weghorn 2020-04-08 06:21:58 UTC
I've seen the crash myself now, and can reliably reproduce with the attached sample doc.

Version: 7.0.0.alpha0+
Build ID: 9383baa32182
Comment 9 Michael Weghorn 2020-04-08 06:31:52 UTC
Fix pending in Gerrit: https://gerrit.libreoffice.org/c/core/+/91865
Comment 10 Commit Notification 2020-04-08 07:18:06 UTC
Michael Weghorn committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/b7056b800f50eaa861177891ef0ee9d103f65069

tdf#116243 android: Include headerfootermenu.ui

It will be available in 7.0.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.