Bug 101885 - Crash when disabling and reenabling screen reader
Summary: Crash when disabling and reenabling screen reader
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
5.3.0.0.alpha0+
Hardware: All Linux (All)
: medium normal
Assignee: Julien Nabet
URL:
Whiteboard: target:5.4.0 target:5.3.5
Keywords: accessibility, haveBacktrace
Depends on:
Blocks: a11y-Linux
  Show dependency treegraph
 
Reported: 2016-09-04 02:17 UTC by Yousuf Philips (jay)
Modified: 2017-06-05 20:16 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
backtrace (14.30 KB, text/x-log)
2016-09-04 02:21 UTC, Yousuf Philips (jay)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Yousuf Philips (jay) 2016-09-04 02:17:24 UTC
Steps:
1) Open writer with screen reader on
2) right-click > Character
3) Turn off screen reader
4) Switch tab
5) Close dialog
6) Turn on screen reader
7) Crash

Crashes with git build but not TDF build.
Comment 1 Yousuf Philips (jay) 2016-09-04 02:21:20 UTC
Created attachment 127141 [details]
backtrace

This was on Ubuntu Mate 16.04 with orca 3.18.2.

Version: 5.3.0.0.alpha0+
Build ID: d5fab973d0af95c433c5f6a9492014f7db642489
CPU Threads: 4; OS Version: Linux 4.4; UI Render: default; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2016-08-24_00:37:02
Locale: en-US (en_US.UTF-8); Calc: group
Comment 2 V Stuart Foote 2016-09-04 13:22:12 UTC
Can not confirm on Windows 10 Pro 64-bit en-US with NVDA 2016.2.1 and
Version: 5.2.1.2 (x64)
Build ID: 31dd62db80d4e60af04904455ec9c9219178d620
CPU Threads: 8; OS Version: Windows 6.19; UI Render: default; 
Locale: en-US (en_US); Calc: group

nor with recent build of master

Version: 5.3.0.0.alpha0+
Build ID: 696e83b663d4f3e00f23947613f9f3916a4dd14d
CPU Threads: 8; OS Version: Windows 6.19; UI Render: GL; 
TinderBox: Win-x86@42, Branch:master, Time: 2016-09-03_10:21:32
Locale: en-US (en_US); Calc: CL
Comment 3 Aron Budea 2016-09-05 06:18:27 UTC
What do you mean by "Crashes with git build but not TDF build"?
Isn't the one in comment 1 a TDF build?

I also tried with a TDF build, no crash with the steps from description:

Version: 5.3.0.0.alpha0+
Build ID: 4a63c145dcce8411c5707f6b99877cc87a4f6c5d
CPU Threads: 1; OS Version: Linux 4.4; UI Render: default; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2016-08-31_19:54:16
Locale: en-US (en_US.UTF-8); Calc: group
Comment 4 Yousuf Philips (jay) 2016-09-05 12:44:16 UTC
(In reply to Aron Budea from comment #3)
> What do you mean by "Crashes with git build but not TDF build"?

LO built from git and not a TDF daily build.

> Isn't the one in comment 1 a TDF build?

No that was my mistake, that was the build info for master that i wasnt able to crash.

@Julien: Can you test your master build?

Backtrace is available, so we need a dev to look into it.
Comment 5 Julien Nabet 2016-09-05 18:52:56 UTC
On pc Debian x86-64 with master sources updated today, I don't reproduce this.

However, I don't use merge libs.
Comment 6 Xisco Faulí 2016-09-19 15:29:47 UTC Comment hidden (obsolete)
Comment 7 Alex ARNAUD 2017-02-09 15:38:28 UTC
Dear Jay,

On TDF LibreOfficeDev 5.4 and the Debian 5.2.5 package I cannot reproduce the crash with the steps you mentioned.

Are you still able to reproduce this crash?

Best regards.
Comment 8 Xisco Faulí 2017-02-24 14:34:58 UTC
Closing as RESOLVED WORKSFORME as per comment 7
Comment 9 Yousuf Philips (jay) 2017-05-03 09:39:25 UTC
(In reply to Xisco Faulí from comment #8)
> Closing as RESOLVED WORKSFORME as per comment 7

Comment 7 is for a TDF build and i mentioned it crashed in a GIT build.
Comment 10 Julien Nabet 2017-05-13 15:33:27 UTC
I gave a try with this:
https://gerrit.libreoffice.org/#/c/37575/
I'm waiting for Jenkins TBs and push it if ok.
Then I'll wait for your feedback before cherry-picking it on 5.3 branch

Even if this patch solves your pb, I think it's more a band aid than a real fix.
Indeed, accessibility part seems a bit messy. Sometimes, functions return 0, others -1, some throw Runtime exception, ...

It'd be great to see more people fixing buggy things instead of adding brand new exciting things but quite uncomplete or buggy too.
Comment 11 Commit Notification 2017-05-13 16:21:54 UTC
Julien Nabet committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=c9275062ed745a8c5d52a3863299baf8bcf86ea7

tdf#101885: fix crash in AccFrameSelector

It will be available in 5.4.0.

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

Affected users are encouraged to test the fix and report feedback.
Comment 12 Michael Meeks 2017-05-13 16:51:38 UTC
Looks like a sensible patch to me; I'd be inclined to return -1 or some other OOB data for when we have no parent (no idea what we do elsewhere for that). Either way fix looks sensible enough for me; a11y deals with lots of corner-cases like this, we can't control how long people keep handles for accessible peers - often long after the object has been destroyed.
Comment 13 Julien Nabet 2017-06-05 16:32:36 UTC
Had forgotten about this one.
Anyone, I cherry-picked it for review on 5.3 branch (see https://gerrit.libreoffice.org/#/c/38414/)
Let's put this one to FIXED.
Comment 14 Commit Notification 2017-06-05 20:16:22 UTC
Julien Nabet committed a patch related to this issue.
It has been pushed to "libreoffice-5-3":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=75d14731e79b66a75e2d3327b94721f6218eb4d7&h=libreoffice-5-3

tdf#101885: fix crash in AccFrameSelector

It will be available in 5.3.5.

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

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