Bug 76169 - registry corruption during crash triggers X misbehavior
Summary: registry corruption during crash triggers X misbehavior
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
4.2.2.1 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-14 12:02 UTC by Frank Griffin
Modified: 2018-02-26 11:24 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
registrymodifications.xcu which causes the error (deleted)
2014-03-14 12:02 UTC, Frank Griffin
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Frank Griffin 2014-03-14 12:02:37 UTC
Created attachment 95801 [details]
registrymodifications.xcu which causes the error

I opened LO to an Untitled document, pasted in some text, did some editing, and tried a "Save As".  While trying to navigate into the correct directory, LO crashed.

After that, all attempts to restart LO opened a grey window with no text which was unresponsive to Close (X) attempts.  Run from a terminal, I get:

[ftg@jaglap ~]$ soffice
X Error: BadMatch (invalid parameter attributes) 8
  Major opcode: 42 (X_SetInputFocus)
  Resource id:  0x840002f

Renaming .config/libreoffice/4 fixed the problem.

I then restored each subdirectory from the failing config to the new one, one by one, testing each time.  All of the directories restored without causing the error.  The culprit turned out to be registrymodifications.xcu, which I will attach.
Comment 1 Stephan Bergmann 2014-03-14 12:40:11 UTC
The attached registrymodification.xcu indicates that LO wants to display the Document Recovery dialog on the next start, which it apparently fails to do for you, while I cannot reproduce any problems here (Fedora 20, Gnome) when using that registrymodifications.xcu.

From the "X_SetInputFocus" X error msg and your description of trying "Save As," this is probably a duplicate of (KDE-specific) bug 69279.  Are you using KDE?
Comment 2 Frank Griffin 2014-03-14 12:58:37 UTC
Looks pretty close, and yes, I am using KDE.  But that explains the initial crash, not the recurring problem on startup.  Document Recovery doesn't involve the File Chooser (that I know of), unless the fact that it crashed in the File Chooser means it's trying to restart it.

Can you tell me how to manually disable Document Recovery in the xcu file ?  I can see if that makes a difference.

Also, tracing your bug reference back to bug#69002, it looks like this was fixed in LO but then regressed, so the status really isn't clear at this point.
Comment 3 Stephan Bergmann 2014-03-14 13:43:09 UTC
(In reply to comment #2)
> Looks pretty close, and yes, I am using KDE.  But that explains the initial
> crash, not the recurring problem on startup.  Document Recovery doesn't
> involve the File Chooser (that I know of), unless the fact that it crashed
> in the File Chooser means it's trying to restart it.

Indeed, somewhat odd.

> Can you tell me how to manually disable Document Recovery in the xcu file ? 
> I can see if that makes a difference.

There is three consecutive lines each starting with

> <item oor:path="/org.openoffice.Office.Recovery/

in your registrymodifications.xcu.  If you remove all three, LO should no longer
try to display the Document Recovery dialog on the next start.

> Also, tracing your bug reference back to bug#69002, it looks like this was
> fixed in LO but then regressed, so the status really isn't clear at this
> point.

Maybe bug 69279 is not exactly a duplicate of bug 69002 after all.  Likely that there are multiple KDE-related issues.
Comment 4 Frank Griffin 2014-03-14 14:04:14 UTC
Eliminating those 3 XML elements makes the problem go away.

Not sure what to do with this.  I don't get the "recursive repaint" error that seems constant in bug#69279 , unless that's due to a different log message level.  OTOH, the patch mentioned in bug#69002 is specific to recursive repaint.

Also not sure whether this patch is in 4.2.2.1 or whether the regression noticed in 4.1.5.3 persists in 4.2.2.1.
Comment 5 Joel Madero 2014-06-18 20:08:21 UTC
From what I can understand this is resolved and should not occur again. I am marking as RESOLVED -> WFM.

If you can still reproduce this with a clean document with 4.2.5 or 4.3 RC1 please set to UNCONFIRMED again. Thanks!
Comment 6 Xisco Faulí 2018-02-26 11:24:33 UTC
The content of attachment 95801 [details] has been deleted