Issue 125147 - CRASH applying styles to text
Summary: CRASH applying styles to text
Status: CLOSED FIXED
Alias: None
Product: Writer
Classification: Application
Component: formatting (show other issues)
Version: 4.1.0
Hardware: PC Linux 64-bit
: P2 Critical with 1 vote (vote)
Target Milestone: 4.1.4
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: regression
Depends on:
Blocks: 127315
  Show dependency tree
 
Reported: 2014-06-23 20:36 UTC by Pete K.
Modified: 2017-10-21 18:14 UTC (History)
8 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: 4.1.3
Developer Difficulty: ---
arielch: 4.1.4_release_blocker+


Attachments
output of strace -ttTf -o strace.txt openoffice4 (zipped) (464.76 KB, application/octet-stream)
2014-06-24 18:49 UTC, Pete K.
no flags Details
Output of catchsegv openoffice4 (82.03 KB, text/plain)
2014-07-08 19:50 UTC, Pete K.
no flags Details
rpm -qa output (61.00 KB, text/plain)
2015-02-09 11:20 UTC, Frank M.
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Pete K. 2014-06-23 20:36:36 UTC
OVERVIEW

AOO 4.1 on Linux crashes -- without reliably prompting for recovery -- when applying a style to a new text document.

STEPS TO REPRODUCE

1) Move /opt/openoffice4/share/extensions to /opt/openoffice4/share/extensions-disabled to ensure no extensions are causing problems.
2) Create a new empty directory /opt/openoffice4/share/extensions.
3) Move ~/.openoffice/4/user to ~/.openoffice/4/user-aside to ensure profile is not causing problems.
4) Start OpenOffice using command line openoffice4 in Gnome Terminal.
5) Click the button to create a new Text document.
6) Type a word.  I used "word".
7) Double-click "word".  
8) Open the sidebar and choose the Styles icon (looks like a party hat).
9) Click to select the "character" styles.  
10) Pick any style and double-click it to apply.

ACTUAL RESULTS

AOO crashes.

EXPECTED RESULTS

Style should be applied to the text.  Nothing should crash.

BUILD DATE AND HARDWARE

2014-04-22 12:11 - Linux x86_64

OPERATING ENVIRONMENT

RHEL 6.5 - Kernel Linux 2.6.32-431.21.1.el6.x86_64 - Gnome 2.28.2
Lenovo ThinkPad T420 with AOO running on external monitor attached by VGA
Comment 1 Pete K. 2014-06-24 18:49:58 UTC
Created attachment 83595 [details]
output of strace -ttTf -o strace.txt openoffice4 (zipped)
Comment 2 Pete K. 2014-06-24 18:52:01 UTC
Running under strace produced the following console output:

===================================
[pkidwell@oc2847425224 ~]$ strace -ttTf -o strace.txt openoffice4
execute Job is called.

In early start
Trying to upload file: usagelog_apache.PBLZPX7.062014.log
inside on New

.odt file has been created
/opt/openoffice4/program/soffice: line 121: 12351 Segmentation fault      "$sd_prog/$sd_binary" "$@"
===================================

Full strace output is attached.  Quick look showed SegFault happens after read from fd=13, which is connected (much earlier) as:

12351 14:37:02.642106 connect(13, {sa_family=AF_FILE, path="/tmp/orbit-pkidwell/linc-79f6-0-2593046c607d"}, 47) = 0 <0.000515>
Comment 3 Pete K. 2014-06-24 19:43:01 UTC
Can not duplicate on Windows 7!  (Installed AOO4.1.0 fresh from website on Windows 7 running in KVM.)
Comment 4 Pete K. 2014-06-24 20:41:25 UTC
I gave up, uninstalled 4.1.0, and installed 4.0.1 on my Linux system.  I can not reproduce the bug on 4.0.1.  So I have marked this bug with keyword REGRESSION.
Comment 5 Ariel Constenla-Haile 2014-06-24 22:08:46 UTC
I cannot reproduce this.
I'd suggest to try with a nightly build from http://ci.apache.org/projects/openoffice/#linux64
Comment 6 Ariel Constenla-Haile 2014-06-24 22:16:07 UTC
(In reply to Pete K. from comment #0)
> 3) Move ~/.openoffice/4/user to ~/.openoffice/4/user-aside to ensure profile
> is not causing problems.

You can test with a brand new profile using -env:UserInstallation, for example:

]$ openoffice4 -env:UserInstallation=file:///tmp/aoo-test
Comment 7 Oliver-Rainer Wittmann 2014-07-02 10:20:33 UTC
I could not reproduce the crash under Ubuntu 10.04 (64bit) with AOO 4.1.0

It looks like as if the described defect depends on a certain system configuration.

@Pete K.:
Do you have further information about your system and your installed AOO version:
- locale
- language of AOO version
- AOO using any installed Java. if yes, which
- ...


adding keyword 'needmoreinfo', keeping keyword 'regression' unless nobody else reproduce, but submitter did not observe the defect on the same system with previous version.
Comment 8 hdu@apache.org 2014-07-02 11:50:20 UTC
Cannot reproduce on RHEL6.4 with AOO410.

The provided strace shows that gnome's GIO virtual filesystem might be involved. A backtrace of the crash stack could confirm this. Why GIO gets active for such a sidebar action is not understood though...
Comment 9 Pete K. 2014-07-08 19:16:47 UTC
Tested and reproduced the crash on nightly build:

AOO420m1(Build:9800) - Rev 1605069
2014-06-25_04:11:22 - Rev. 1605250

@Oliver: Locale is en-us, language US English.  Java is showing up (under Tools > Options > Java) as Sun Microsystems 1.6.0_30 (in /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64/jre). No parameters or class path showing.

@hdu: How might I get a "backtrace of the crash stack"?
Comment 10 Pete K. 2014-07-08 19:50:10 UTC
Created attachment 83659 [details]
Output of catchsegv openoffice4

Output of catchsegv to generate backtrace and more
Comment 11 Pete K. 2014-07-08 19:51:03 UTC
Well, following my last comment, I googled around until I discovered catchsegv. I attached the output of "catchsegv openoffice4" - seems like accessibility code triggers the crash?  Anyway, hope this helps!
Comment 12 Oliver-Rainer Wittmann 2014-07-09 07:45:10 UTC
@Steve: Could you please have a look? Due to Pete's findings the defect is caused by a certain accessibility code.
Comment 13 Steve Yin 2014-07-15 05:47:53 UTC
(In reply to Oliver-Rainer Wittmann from comment #12)
> @Steve: Could you please have a look? Due to Pete's findings the defect is
> caused by a certain accessibility code.

I'll try to reproduce it firstly.
Comment 14 Pete K. 2014-08-22 13:05:18 UTC
Confirmed that this issue still exists in AOO 4.1.1 on RedHat Enterprise Linux 6.5
Comment 15 Pete K. 2014-08-22 13:10:30 UTC
I am raising this to P2/Critical.  At this point the crash is preventing me from upgrading from 4.0.1 to 4.1.1 on RHEL 6.5.  This means that I am missing the security fixes that were included in 4.1.1.
Comment 16 Frank M. 2015-02-05 15:55:15 UTC
(In reply to Pete K. from comment #15)

I'm seeing exactly the same issue as Pete. I had to fall back to AOO 4.0.1, too.
For me, this problem started with AOO 4.1, and AOO 4.1.1 has it, too.
Comment 17 Kay 2015-02-06 23:27:06 UTC
Can not reproduce on Linux-32 in 4.1.1.

More information is needed from Pete and Frank regarding Linux OS and architecture.
Comment 18 Frank M. 2015-02-09 11:20:41 UTC
Created attachment 84495 [details]
rpm -qa output
Comment 19 Frank M. 2015-02-09 11:22:55 UTC
I'm on Linux RedHat 64 bit.
I've attached the list of installed packages. Please disregard the AOO version, because I had to fall back to 4.0.1.
Which other information would be helpful?
Comment 20 Kay 2015-02-11 23:03:34 UTC
(In reply to Frank M. from comment #19)
> I'm on Linux RedHat 64 bit.
> I've attached the list of installed packages. Please disregard the AOO
> version, because I had to fall back to 4.0.1.
> Which other information would be helpful?

This was very helpful. I changed the OS to Linux64 for now.
Comment 21 Frank M. 2015-02-17 10:25:56 UTC
I found that the problem disappears when I remove a setting from the file
~/.gconf/desktop/gnome/interface/%gconf.xml 

The problematic line is
<entry name="accessibility" mtime="1398169534" type="bool" value="true"/>

After removing this setting, AOO does not crash.
Comment 22 hanya 2015-02-17 17:56:18 UTC
Good finding.

I could reproduce the crash with the accesibility enabled on Cent OS 6.6 x86_64 and AOO 4.1.1 working inside virtual environment.
Check Gnome - System - Preferences - Assistive Technologies - Enable assistive technologies checkbox. And then relog.
Follow the procedure written in the description.
Comment 23 hanya 2015-03-24 17:03:39 UTC
The issue caused in SvTreeListBox::IsSelected method called from 
SvTreeListBox::FillAccessibleEntryStateSet method. 
If the passed entry is not found in the aDataTable, NULL pointer is used. 
HasEntryFocus method also gave me crash after the hack for IsSelected method. 
And also, NULL entry passed to FillAccessibleEntryStateSet was also happen.
Comment 24 hanya 2015-03-24 17:10:17 UTC
Fixed on trunk, revision 1668939.
Comment 25 Matthias Seidel 2016-09-19 10:17:56 UTC
(In reply to hanya from comment #24)
> Fixed on trunk, revision 1668939.

Has this fix been applied/tested only for english language?

Because the same crash still occurs in AOO4.1.2 on other languages (german, french and swedish are confirmed). -> Issue 126980

I see the target milestone is 4.2.0?
It would be better now to set it to 4.1.3 and ask for release blocker...
Comment 26 hanya 2016-09-19 11:33:56 UTC
(In reply to Matthias Seidel from comment #25)
> (In reply to hanya from comment #24)
> > Fixed on trunk, revision 1668939.
> 
> Has this fix been applied/tested only for english language?
> 
> Because the same crash still occurs in AOO4.1.2 on other languages (german,
> french and swedish are confirmed). -> Issue 126980
I could confirm issue 126980 even with en-US on Ubutntu 16.04.1. This issue 125147 does not related to any language pack. 
But the reson of the crash is the same, null pointer referencing.

> I see the target milestone is 4.2.0?
> It would be better now to set it to 4.1.3 and ask for release blocker...
If it would be part of 4.1.3, it's better. I thought next release would be 4.2 when I found the fix.
Comment 27 Matthias Seidel 2016-09-19 11:46:26 UTC
(In reply to hanya from comment #26)

> If it would be part of 4.1.3, it's better. I thought next release would be
> 4.2 when I found the fix.

Well, at that time there was no 4.1.3 planned... ;-)
Can anyone change the target milestone? I have no rights.

Interesting that issue 126980 occurs for you in en-US (OK, I only tested with en-GB). But I have at least 2 other reproducible crashes which may be caused by the same problem.

One is issue 125762.
Comment 28 Matthias Seidel 2016-09-22 21:34:31 UTC
Tested with a 4.2.0 dev build of SVN r1761670 (Ubuntu 16.04.1 / 64bit) and the problem is no longer visible!
Comment 29 Matthias Seidel 2016-10-06 20:21:43 UTC
(In reply to hanya from comment #24)
> Fixed on trunk, revision 1668939.

This fix should be included in 4.1.4

It solves most of the crashes in Ubuntu (and maybe any distibution with agnome-based DE?) together with https://svn.apache.org/viewvc?view=rev&rev=1761439.
Comment 30 SVN Robot 2017-02-02 21:49:29 UTC
"arielch" committed SVN revision 1781472 into branches/AOO414:
i125147 - Prevent NULL pointer dereference
Comment 31 Ariel Constenla-Haile 2017-02-02 21:50:35 UTC
Merged Revision 1668939 in branch AOO414
Comment 32 Kay 2017-08-17 20:46:50 UTC
Verified fixed on 4.1.4 RC2 Rev. 1804788 Linux-32.
Comment 33 Kay 2017-08-17 20:56:54 UTC
change back to RESOLVED until final release.
Comment 34 Kay 2017-10-12 21:31:23 UTC
Still fixed for AOO 4.1.4 RC5,  Rev. 1811857 based on Linux-32 testing.