Bug 92936 - FILESAVE: HSQLDB:Inserting big image in a form destroys all input since last opening of *.odb-file
Summary: FILESAVE: HSQLDB:Inserting big image in a form destroys all input since last ...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: x86-64 (AMD64) All
: medium major
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
: 123486 139943 (view as bug list)
Depends on:
Blocks: Base-Images Database-HSQLDB
  Show dependency treegraph
 
Reported: 2015-07-26 06:35 UTC by Robert Großkopf
Modified: 2023-07-20 07:41 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
Database for testing image-input (11.08 KB, application/vnd.oasis.opendocument.database)
2015-07-26 06:35 UTC, Robert Großkopf
Details
Screenshot first NullPointerException (61.21 KB, image/png)
2015-07-26 06:37 UTC, Robert Großkopf
Details
Screenshot of second NullPointerException (30.40 KB, image/png)
2015-07-26 06:38 UTC, Robert Großkopf
Details
bt on master (41.95 KB, text/plain)
2015-07-31 09:36 UTC, Alex Thurgood
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Großkopf 2015-07-26 06:35:51 UTC
Created attachment 117439 [details]
Database for testing image-input

For reproduction of this bug you must have some photos from a digicam. I have tested this with some photos 3 MB.

Open the attached database.
Open the form.
Write down for Text: '1'
Insert the first image by dubbleclick on the imagecontrol.
Goto next record.
It fails here when trying to insert image 4. Could be you could insert some more images. It doesn't go to next record but throws an error: java.lang.NullPointerException

Cancel the last insert.
Close the form.
Try to open the table.
No data could be loaded - same error is reported.
Close the Base-file.
Reopen the Base-file.
No data in the table, but there were saved 3 rows before.
(Remark: This 3 rows would be saved if using LO 3.5 - afterwords the file will be reset automatically by SHUTDOWN COMPACT)

The error appears in all LO-versions. So I set this on Inherited From OOo.
My System: OpenSUSE 13.2 64bit rpm Linux, different LO-Versions, tested also with LO 4.4.4
Comment 1 Robert Großkopf 2015-07-26 06:37:28 UTC
Created attachment 117440 [details]
Screenshot first NullPointerException

Note: The exception is thrown by 4th record. It depends on how big the images are.
Comment 2 Robert Großkopf 2015-07-26 06:38:46 UTC
Created attachment 117441 [details]
Screenshot of second NullPointerException

Table could not be opened. When closing Base all data since last opening of the file were lost.
Comment 3 Alex Thurgood 2015-07-31 08:27:24 UTC
On Master 5.1 alpha, OSX 10.10.4, I don't a NullPointerException, but I do see the "java.io.IOException: Stream is not valid" error message. 

This occurs when attempting to validate a 4.4Mb image insert into the control.

Unfortunately, clicking on "More" brings no further information. If I click on "OK", it removes the error message, but then I can do nothing else with the form, if I try to navigate forward or backwards, I get the same error message again.

Attempting to Save or Create New tuple also displays the same error message

If I try to close the Form, I get the message telling me that the data in the form has changed, do I want to save ? Answering yes, throws the same error message, answering No brings me back to the main odb interface.

If I then close the ODB window, LO dies and displays Apple Crash Report

Confirming
Comment 4 Alex Thurgood 2015-07-31 08:31:18 UTC
If I try to recover the file on next LO launch, the file contains none of the previously entered data, it is essentially "clean".
Comment 5 Alex Thurgood 2015-07-31 08:32:03 UTC
My tests with 3.5 to 5Mb images caused the failure at the second insert.
Comment 6 Alex Thurgood 2015-07-31 08:40:13 UTC
Attempting to open the Form in LO 4341 or 4332 causes an instant abort.

JDK version 1.8.0_45
Comment 7 Alex Thurgood 2015-07-31 08:43:23 UTC
With LO 3672 and JDK 1.6.0_65, I can insert up to 4 images, and then it fails with the message Robert posted.
Comment 8 Alex Thurgood 2015-07-31 08:48:25 UTC
(In reply to Alex Thurgood from comment #7)
> With LO 3672 and JDK 1.6.0_65, I can insert up to 4 images, and then it
> fails with the message Robert posted.

If I cancel the failed insert using the Reverse button in the toolbar, then close the form, none of the previously entered data is saved. Any attempt to open the corresponding table results in a select failure.
Comment 9 Alex Thurgood 2015-07-31 08:58:37 UTC
In Version: 5.1.0.0.alpha1+
Build ID: e2281331b1ab40288494ab3659d9c66e13d3e905
Locale : fr-FR (fr.UTF-8)

JDK 1.8.0_51

loading the form from lldb leads to a stopped process while attempting to read the autoincrement value from the first field :

* thread #25: tid = 0xcb1e1, 0x000000012fc03fd7, stop reason = signal SIGBUS
    frame #0: 0x000000012fc03fd7
->  0x12fc03fd7: testl  -0x24e88fdd(%rip), %eax
    0x12fc03fdd: retq   
    0x12fc03fde: movl   0xc(%r12,%rbx,8), %r13d
    0x12fc03fe3: jmp    0x12fc03f2f
Comment 10 Alex Thurgood 2015-07-31 09:25:51 UTC
Stepping through the inserts, lldb spits this out when moving to next record :

warn:legacy.tools:5807:1:vcl/inc/svdata.hxx:389: object deleted while in use !
Comment 11 Alex Thurgood 2015-07-31 09:35:56 UTC
Closing the Form, then attempting to close the ODB file leads to another stoppage :

Process 5807 stopped
* thread #25: tid = 0xcb1e1, 0x000000012fa1fa6e, stop reason = signal SIGSEGV
    frame #0: 0x000000012fa1fa6e
->  0x12fa1fa6e: movl   0x8(%rcx), %edx
    0x12fa1fa71: shlq   $0x3, %rdx
    0x12fa1fa75: movq   -0x20(%rbp), %r13
    0x12fa1fa79: testq  %r13, %r13

Process 5807 resuming
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed


Then LOdev has to be closed from the Dock via the menu entry Quit :
 
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed
warn:legacy.osl:5807:1:include/cppuhelper/interfacecontainer.h:479: object is disposed
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:legacy.tools:5807:1:basic/source/sbx/sbxobj.cxx:98: Object element with dangling parent
warn:sal.osl.pipe:5807:1:sal/osl/unx/pipe.cxx:395: shutdown() failed: Socket is not connected
warn:sal.osl.pipe:5807:3:sal/osl/unx/pipe.cxx:436: accept() failed: Software caused connection abort
warn:legacy.osl:5807:1:unotools/source/config/configmgr.cxx:168: OSL_ASSERT: items_.empty()
Process 5807 exited with status = 0 (0x00000000) 
(lldb)
Comment 12 Alex Thurgood 2015-07-31 09:36:39 UTC
Created attachment 117557 [details]
bt on master
Comment 13 Julien Nabet 2015-08-02 08:32:43 UTC
On pc Debian x86-64 with master sources updated yesterday, I could reproduce this.

Here's the detail of the message:
Statut SQL: S1000
Code d'erreur: 98

java.io.IOException: java.lang.NullPointerException in statement [INSERT INTO "Table" ( "Image","Text") VALUES ( ?,?)]

I noticed too on console:
warn:vcl.window:18296:1:vcl/source/window/window.cxx:3426: ignoring RuntimeException "unsatisfied query for interface of type com.sun.star.datatransfer.clipboard.XClipboard!"
Comment 14 QA Administrators 2016-09-20 10:21:45 UTC Comment hidden (obsolete)
Comment 15 Robert Großkopf 2016-10-01 09:56:58 UTC
Nothing changed for LO 5.2.2.2 on OpenSUSE 42.1 64bit rpm Linux.
Comment 16 QA Administrators 2018-02-08 03:35:56 UTC Comment hidden (obsolete)
Comment 17 Robert Großkopf 2018-02-09 06:57:43 UTC
Tested again with
Version: 6.0.0.3
Build-ID: 64a0f66915f38c6217de274f0aa8e15618924765
CPU-Threads: 4; BS: Linux 4.4; UI-Render: Standard; VCL: kde4; 
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group

Bug hasn't changed in OpenSUSE 42.2 64 bit rpm Linux.
Comment 18 QA Administrators 2019-02-10 03:44:08 UTC Comment hidden (obsolete)
Comment 19 Robert Großkopf 2019-02-10 07:54:17 UTC
Bug still exits in LO 6.1.5.2 on OpenSUSE 15, 64bit rpm Linux.
Comment 20 Robert Großkopf 2019-02-10 08:02:47 UTC
Note: With Firebird you could "save" as much images as you want. Could be they are inside the *.odb-file (it's getting bigger and bigger) but no image will be displayed in the form.

This bug for big images is a special HSQLDB-bug. I will change the title to show this.
Comment 21 Robert Großkopf 2019-02-18 13:27:00 UTC
*** Bug 123486 has been marked as a duplicate of this bug. ***
Comment 22 Buovjaga 2021-07-19 09:24:30 UTC
*** Bug 139943 has been marked as a duplicate of this bug. ***
Comment 23 QA Administrators 2023-07-20 03:17:41 UTC Comment hidden (obsolete)
Comment 24 Robert Großkopf 2023-07-20 07:41:13 UTC
Bug is still the same in
Version: 7.6.0.1 (X86_64) / LibreOffice Community
Build ID: 776eaf34564cbf3f034a0ba1fd1d5c32ff9ccf1c
CPU threads: 6; OS: Linux 5.14; UI render: default; VCL: kf5 (cairo+xcb)
Locale: de-DE (de_DE.UTF-8); UI: de-DE
Calc: threaded