Issue 92253 - [a11y] Exiting Relation Design window after saving a relationship crashes OOo
Summary: [a11y] Exiting Relation Design window after saving a relationship crashes OOo
Status: CLOSED FIXED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: OOo 2.4.1
Hardware: All Linux, all
: P2 Trivial (vote)
Target Milestone: OOo 3.0.1
Assignee: Frank Schönheit
QA Contact: issues@dba
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-07-29 16:24 UTC by dashian
Modified: 2009-07-20 14:52 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Crash output my system generated (12.30 KB, text/plain)
2008-07-29 16:26 UTC, dashian
no flags Details
patches to workaround crash (3.12 KB, patch)
2008-07-30 15:11 UTC, caolanm
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description dashian 2008-07-29 16:24:01 UTC
FC 9, x86_64 install. Fully updated. System-Administration-Add Remove Software
to install openoffice.org-base-1:2.4.1-17.4.fc9 (x86_64).

Two tables Main and Positive. Main used ID field for primary key, Positive uses
"Positive" field for primary key. Main has "positive" as one of it's fields.
These tables created using the design view but have duplicated from generating
tables by other means with other field names.

Select Tools-Relationships, Relation design window opens, Add tables window
opens, ADD both tables, Close add tables window, Drag "Positive" from Positive
table to "positive" in Main table, line shows up linking the two, click save
icon, click "x" in upper right corner to close window, Crash

Output will be attached in a file.
Comment 1 dashian 2008-07-29 16:26:30 UTC
Created attachment 55420 [details]
Crash output my system generated
Comment 2 dashian 2008-07-29 20:58:09 UTC
Found how to stop the crashing.

5) Going back in, restore, close, run Base, open existing, open Relation Design,
remove relationship tables, save, save DB, Close relation design window, OOo
does not crash.

This suggests to me that merely table being present in the relation design
window, causes the crash. I have now checked this by going back in and just
adding one table to the relation design window, saved Relation design and the
DB, moved the window so I could see what happens. On closing the window it does
crash as does trying to exit Base. When the crash happens the title of the table
window in the relation design window changes to "bad".

....

The following is the steps I tried to discover more information. I have numbered
the following items based on their order. I Copied the most important one at the
top to help ensure it is not overlooked.

1)After I go back into the document I can restore it and save it.
Closing and opening again after restore works.
At this point opening the Relation Design window shows the relation set up
previously as existing.
Closing the relation design window crashes OOo. No other action taken than to
click on the x in the upper right hand corner.

2)Going back in, restore, close, run Base, open existing, open Relation Design,
remove relationship, save, Close relation design window, OOo crashes.

3)Going back in, restore, close, run Base, open existing, open Relation Design,
remove relationship, save, save DB, Close relation design window, OOo crashes.

4)Going back in, restore, close, run Base, open existing, open Relation Design,
relationship now removed, Close relation design window, OOo crashes.

5)Going back in, restore, close, run Base, open existing, open Relation Design,
remove relationship tables, save, save DB, Close relation design window, OOo
does not crash.
Comment 3 Frank Schönheit 2008-07-29 21:00:51 UTC
note that you're in the issue tracking system of the main OpenOffice.org project
(www.openoffice.org) here.
We do not provide 64 bit builds at the moment, the version you named sounds as
if you got it from go-ooo.org, which effectively is a fork of OpenOffice.org.

Since its hard to to guess whether the bug you describe is specific to this
fork, or would also be present in a regular 64 bit build, if we had one, it
might take a while until your issue is handled. (In fact, there are people which
would suggest to immediately close the issue - I am reluctant to do this, since
in fact the problem might be in the main OOo code base, and not specific to the
fork).

In any way, I suggest you raise the issue at the place where you got your build
from.
Comment 4 dashian 2008-07-29 23:15:27 UTC
I will try that.

The build I am using is from the main Fedora Core repository. I will check there
first.

Should some solution happen I will post what I can here if the topic is not closed.
Comment 5 Frank Schönheit 2008-07-29 23:18:51 UTC
Thanks.
Comment 6 dashian 2008-07-30 11:17:41 UTC
Work around is to disable accessibility features under
system-preferences-personal-assistive technologies and restart the session.

Caolan McNamara at RedHat is looking into the problem:
https://bugzilla.redhat.com/show_bug.cgi?id=457193
Comment 7 caolanm 2008-07-30 15:11:01 UTC
FWIW it's a Fedora build and Fedora doesn't use go-ooo.org, just vanilla OOO
with just the patches at issue 90439 added. From the trace this is with
accessibility enabled and after enabling accessibility I can reproduce this on i386.

There are a few problems, at least one is that TableWindow has a accessibility
object associated with it that references that TableWindow, when the TableWindow
dtor is finished the OTableWindowAccess still references that dtored window and
eventually calls GetText on it.

I don't have any real solutions to the problems, but I attach a pair of
workarounds to make them "go away" which should help illustrate the problem anyway. 
Comment 8 caolanm 2008-07-30 15:11:37 UTC
Created attachment 55451 [details]
patches to workaround crash
Comment 9 caolanm 2008-07-30 15:12:33 UTC
a11y specific rather than F-9 specific
Comment 10 Frank Schönheit 2008-07-30 20:58:58 UTC
Caolan, thanks for the investigations.

That's Ocke's issue then.
Comment 11 ocke.janssen 2008-08-12 07:23:12 UTC
I modified the patch a little bit. Now I overload the method ProcessWindowEvent
and set table to NULL when it is dying.

void OTableWindowAccess::ProcessWindowEvent( const VclWindowEvent& rVclWindowEvent )
	{
        if ( rVclWindowEvent.GetId() == VCLEVENT_OBJECT_DYING )
            m_pTable = NULL;

        VCLXAccessibleComponent::ProcessWindowEvent( rVclWindowEvent );
	}
Comment 12 ocke.janssen 2008-10-28 08:41:02 UTC
Please review the patch I've done. Thanks.

cd dbaccess\source\ui\querydesign
cvs diff -r1.14 -r1.14.34.1 TableWindowAccess.cxx
Comment 13 Frank Schönheit 2008-10-29 08:56:45 UTC
fs->oj:
- ProcessWindowEvent should lock m_aMutex before setting m_pTable to NULL, since
  this assignment is no atomic operation.
- Not related to this bug here, but while you are there: ::containsRelation
  does not check m_pTable for being != NULL before accessing it, this has the
  potential for another crash.
Comment 14 Frank Schönheit 2008-10-30 14:18:07 UTC
looks good now
Comment 15 thorsten.ziehm 2009-07-20 14:52:17 UTC
This issue is closed automatically and wasn't rechecked in a current version of
OOo. The fixed issue should be integrated in OOo since more than half a year. If
you think this issue isn't fixed in a current version (OOo 3.1), please reopen
it and change the field 'Target Milestone' accordingly.

If you want to download a current version of OOo =>
http://download.openoffice.org/index.html
If you want to know more about the handling of fixed/verified issues =>
http://wiki.services.openoffice.org/wiki/Handle_fixed_verified_issues