[Upstream] LibreOffice Base connection to mdb via odbc crashes on saving odb file

Bug #1242355 reported by magowiz
24
This bug affects 1 person
Affects Status Importance Assigned to Milestone
LibreOffice
Won't Fix
Critical
libreoffice (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

I was trying to connect to an existing mdb (MS Access) database file using unixodbc and libreoffice-base,
I've got unixodbc , undixodbc-bin and libmdbodbc1 packages installed
I set the odbc as following :

/etc/odbc.ini
[Pippo]
Description = mine database
Driver = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Database = /home/magowiz/pippo.mdb

/etc/odbcinst.ini
[MDBTools]
Description = MDBTools Driver
Driver = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Setup = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Usage = 1
FileUsage = 1
UsageCount = 2

I use the connection wizard into libreoffice base : I can successfully test mine connection but while I'm saving the odb file the whole program crashes and close itself

It follows distro and software versions :

$ lsb_release -rd
Description: Ubuntu 13.10
Release: 13.10

apt-cache policy libreoffice-base
libreoffice-base:
  Installed: 1:4.1.2~rc3-0ubuntu1
  Candidate: 1:4.1.2~rc3-0ubuntu1

apt-cache policy unixodbc
unixodbc:
  Installed: 2.2.14p2-5ubuntu4
  Candidate: 2.2.14p2-5ubuntu4

apt-cache policy libmdbodbc1
libmdbodbc1:
  Installed: 0.7-3
  Candidate: 0.7-3

ProblemType: Crash
DistroRelease: Ubuntu 13.10
Package: libreoffice-core 1:4.1.2~rc3-0ubuntu1 [modified: usr/lib/libreoffice/program/libcomphelper.so usr/lib/libreoffice/program/libi18nlangtag.so usr/lib/libreoffice/program/libmergedlo.so usr/lib/libreoffice/program/libspalo.so usr/lib/libreoffice/program/libucbhelper.so usr/lib/libreoffice/program/libunopkgapp.so usr/lib/libreoffice/program/oosplash usr/lib/libreoffice/program/pluginapp.bin usr/lib/libreoffice/program/soffice.bin usr/lib/libreoffice/program/spadmin.bin usr/lib/libreoffice/program/unopkg.bin usr/lib/libreoffice/program/uri-encode]
ProcVersionSignature: Ubuntu 3.11.0-12.19-generic 3.11.3
Uname: Linux 3.11.0-12-generic x86_64
NonfreeKernelModules: wl
ApportVersion: 2.12.5-0ubuntu2
Architecture: amd64
CrashCounter: 1
Date: Sun Oct 20 16:19:16 2013
ExecutablePath: /usr/lib/libreoffice/program/soffice.bin
MarkForUpload: True
ProcCmdline: /usr/lib/libreoffice/program/soffice.bin --splash-pipe=5
SegvAnalysis: Skipped: missing required field "Disassembly"
Signal: 11
SourcePackage: libreoffice
Stacktrace:
 No symbol "__nih_abort_msg" in current context.
 Python Exception <class 'AttributeError'> 'dict' object has no attribute 'iteritems':
 Python Exception <class 'AttributeError'> 'dict' object has no attribute 'iteritems':
StacktraceTop:

Title: soffice.bin crashed with SIGSEGV
UpgradeStatus: Upgraded to saucy on 2013-10-17 (2 days ago)
UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo
---
ApportVersion: 2.12.5-0ubuntu2.1
Architecture: amd64
DistroRelease: Ubuntu 13.10
MarkForUpload: True
NonfreeKernelModules: wl
Package: libreoffice 1:4.1.3-0ubuntu1
PackageArchitecture: amd64
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=it_IT.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 3.11.0-14.21-generic 3.11.7
Tags: saucy package-from-proposed
Uname: Linux 3.11.0-14-generic x86_64
UpgradeStatus: Upgraded to saucy on 2013-10-17 (37 days ago)
UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo

Revision history for this message
magowiz (magowiz) wrote :
information type: Private → Public
Revision history for this message
Apport retracing service (apport) wrote : Stacktrace.txt
Revision history for this message
Apport retracing service (apport) wrote : StacktraceSource.txt
Revision history for this message
Apport retracing service (apport) wrote : StacktraceTop.txt
Revision history for this message
Apport retracing service (apport) wrote : ThreadStacktrace.txt
Changed in libreoffice (Ubuntu):
importance: Undecided → Medium
tags: removed: need-amd64-retrace
Revision history for this message
penalvch (penalvch) wrote : Re: libreoffice base connection to mdb via odbc crashes on saving odb file

magowiz, could you please attach the database file that demonstrates this problem?

Changed in libreoffice (Ubuntu):
status: New → Incomplete
Revision history for this message
magowiz (magowiz) wrote :

do you need the mdb or the odb created to point to it ?

Revision history for this message
penalvch (penalvch) wrote :

magowiz, both wouldn't hurt.

Revision history for this message
magowiz (magowiz) wrote :
Revision history for this message
magowiz (magowiz) wrote :
  • pippo.odb Edit (1.7 KiB, application/vnd.oasis.opendocument.database)
Revision history for this message
magowiz (magowiz) wrote :

attached both files as requested

penalvch (penalvch)
Changed in libreoffice (Ubuntu):
status: Incomplete → New
Revision history for this message
magowiz (magowiz) wrote :

This bug affects also just released libreoffice 4.1.3 version

Revision history for this message
magowiz (magowiz) wrote : Dependencies.txt

apport information

tags: added: apport-collected package-from-proposed
description: updated
Revision history for this message
penalvch (penalvch) wrote : Re: libreoffice base connection to mdb via odbc crashes on saving odb file

magowiz, thank you for taking the time to report this bug and helping to make Ubuntu better. The issue you are reporting is an upstream one. It would be nice if somebody having it could send the bug to the developers of the software by following the instructions verbatim at http://wiki.documentfoundation.org/BugReport . If you have done so, please tell us the number of the upstream bug (or the link), so we can add a bugwatch that will inform us about the status. Thanks in advance.

Helpful bug reporting tips:
https://help.ubuntu.com/community/ReportingBugs

Revision history for this message
In , magowiz (magowiz) wrote :

Problem description:
I'm trying to connect via odbc to a mdb file using the base wizard, all seems to go fine, also connection test, but just after I choose where to save the odb file and click save, libreoffice crashes, produced file (odb) if opened makes libreoffice crash again.
These are version programs and configurations involved :
I was trying to connect to an existing mdb (MS Access) database file using unixodbc and libreoffice-base,
I've got unixodbc , undixodbc-bin and libmdbodbc1 packages installed
I set the odbc as following :

/etc/odbc.ini
[Pippo]
Description = mine database
Driver = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Database = /home/magowiz/pippo.mdb

/etc/odbcinst.ini
[MDBTools]
Description = MDBTools Driver
Driver = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Setup = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Usage = 1
FileUsage = 1
UsageCount = 2

I use the connection wizard into libreoffice base : I can successfully test mine connection but while I'm saving the odb file the whole program crashes and close itself

It follows distro and software versions :

$ lsb_release -rd
Description: Ubuntu 13.10
Release: 13.10

apt-cache policy libreoffice-base
libreoffice-base:
  Installed: 1:4.1.2~rc3-0ubuntu1
  Candidate: 1:4.1.2~rc3-0ubuntu1

apt-cache policy unixodbc
unixodbc:
  Installed: 2.2.14p2-5ubuntu4
  Candidate: 2.2.14p2-5ubuntu4

apt-cache policy libmdbodbc1
libmdbodbc1:
  Installed: 0.7-3
  Candidate: 0.7-3

Steps to reproduce:
1. configure like described above unixodbc to point to mdb file
2. open libreoffice base and choose to connect via ODBC to db name choosen while configurating unixodbc
3. choose where to save the odb file and then click save

Current behavior:
It crashes just after save button is clicked

Expected behavior:
it should open libreoffice base main interface to make me able to work with the database

The same file can be opened by libreoffice windows version on windows 7

Operating System: Ubuntu
Version: 4.1.3.2 release

Revision history for this message
In , magowiz (magowiz) wrote :

Problem description:
I'm trying to connect via odbc to a mdb file using the base wizard, all seems to go fine, also connection test, but just after I choose where to save the odb file and click save, libreoffice crashes, produced file (odb) if opened makes libreoffice crash again.
These are version programs and configurations involved :
I was trying to connect to an existing mdb (MS Access) database file using unixodbc and libreoffice-base,
I've got unixodbc , undixodbc-bin and libmdbodbc1 packages installed
I set the odbc as following :

/etc/odbc.ini
[Pippo]
Description = mine database
Driver = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Database = /home/magowiz/pippo.mdb

/etc/odbcinst.ini
[MDBTools]
Description = MDBTools Driver
Driver = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Setup = /usr/lib/x86_64-linux-gnu/odbc/libmdbodbc.so.1
Usage = 1
FileUsage = 1
UsageCount = 2

I use the connection wizard into libreoffice base : I can successfully test mine connection but while I'm saving the odb file the whole program crashes and close itself

It follows distro and software versions :

$ lsb_release -rd
Description: Ubuntu 13.10
Release: 13.10

apt-cache policy libreoffice-base
libreoffice-base:
  Installed: 1:4.1.2~rc3-0ubuntu1
  Candidate: 1:4.1.2~rc3-0ubuntu1

apt-cache policy unixodbc
unixodbc:
  Installed: 2.2.14p2-5ubuntu4
  Candidate: 2.2.14p2-5ubuntu4

apt-cache policy libmdbodbc1
libmdbodbc1:
  Installed: 0.7-3
  Candidate: 0.7-3

Steps to reproduce:
1. configure like described above unixodbc to point to mdb file
2. open libreoffice base and choose to connect via ODBC to db name choosen while configurating unixodbc
3. choose where to save the odb file and then click save

Current behavior:
It crashes just after save button is clicked

Expected behavior:
it should open libreoffice base main interface to make me able to work with the database

The same file can be opened by libreoffice windows version on windows 7

Operating System: Ubuntu
Version: 4.1.3.2 release

Revision history for this message
magowiz (magowiz) wrote :

Hi Christoper,
I just submitted a bug report upstream, I hope I did it properly ,
you can find it here : https://www.libreoffice.org/bugzilla/show_bug.cgi?id=71966

penalvch (penalvch)
summary: - libreoffice base connection to mdb via odbc crashes on saving odb file
+ [Upstream] LibreOffice Base connection to mdb via odbc crashes on saving
+ odb file
Changed in df-libreoffice:
importance: Unknown → Critical
status: Unknown → New
Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

Could you please attach the .odb file that makes it crash?

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

Could you please attach the .odb file that makes it crash?

Revision history for this message
In , magowiz (magowiz) wrote :

Created attachment 90103
odb file that points to mdb database

Revision history for this message
In , magowiz (magowiz) wrote :

Created attachment 90103
odb file that points to mdb database

Revision history for this message
In , magowiz (magowiz) wrote :

Created attachment 90104
mdb file that causes the issue.

Revision history for this message
In , magowiz (magowiz) wrote :

Created attachment 90104
mdb file that causes the issue.

Revision history for this message
In , magowiz (magowiz) wrote :

(In reply to comment #1)
> Could you please attach the .odb file that makes it crash?

I attached both mdb and odb file since the odb points to real database : mdb file.

Revision history for this message
In , magowiz (magowiz) wrote :

(In reply to comment #1)
> Could you please attach the .odb file that makes it crash?

I attached both mdb and odb file since the odb points to real database : mdb file.

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

Reproduced on two different machines:
 - libreoffice 4.1.3.2 (Debian package): infinite loop (memory consumption)
 - libreoffice 4.1 my own development tree: segfault in ODBC code

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

Reproduced on two different machines:
 - libreoffice 4.1.3.2 (Debian package): infinite loop (memory consumption)
 - libreoffice 4.1 my own development tree: segfault in ODBC code

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

Crash goes away (on Debian) after upgrading unixodbc to 2.3.1-1. So until hint to the contrary, seems to be a bug in UnixODBC -> NOTOURBUG.

It does not work though, the list of tables is empty. This seems to be a mdbtools bug, because isql also cannot get the list of tables. Try:
  echo help | isql Pippo | less -SIM
It "finds" 10 tables, but no info on them (no name, ...).

The SQLTables function seems to be not implemented in mdbtools, or buggy on your particular example or ... (SQLGetData returns an error code, but subsequent SQLGetDiagRec returns all-zero SQLSTATE, no error string, ...).

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

Crash goes away (on Debian) after upgrading unixodbc to 2.3.1-1. So until hint to the contrary, seems to be a bug in UnixODBC -> NOTOURBUG.

It does not work though, the list of tables is empty. This seems to be a mdbtools bug, because isql also cannot get the list of tables. Try:
  echo help | isql Pippo | less -SIM
It "finds" 10 tables, but no info on them (no name, ...).

The SQLTables function seems to be not implemented in mdbtools, or buggy on your particular example or ... (SQLGetData returns an error code, but subsequent SQLGetDiagRec returns all-zero SQLSTATE, no error string, ...).

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

(In reply to comment #5)
> Reproduced on two different machines:
> - libreoffice 4.1.3.2 (Debian package): infinite loop (memory consumption)

This was with mdbtools 0.7.1-1. This also is a mdbtools bug: calling SQLGetData on column 4 (TABLE_TYPE) of SQLTables returns SQL_NO_TOTAL in StrLen_or_IndPtr, indicating that there is more data to return, but the driver does not know how much. In this case, it returned all the data, namely "SYSTEM TABLE", so it should set StrLen_or_IndPtr to the length of that (that is, 12).

Cf http://msdn.microsoft.com/en-us/library/ms715441%28v=vs.85%29.aspx
Neither SQL_NO_TOTAL nor zero can be returned on the last valid call to retrieve data from a column, because the application would then have no way of knowing how much of the data in the application buffer is valid.

Revision history for this message
In , Lionel Elie Mamane (lionel-mamane) wrote :

(In reply to comment #5)
> Reproduced on two different machines:
> - libreoffice 4.1.3.2 (Debian package): infinite loop (memory consumption)

This was with mdbtools 0.7.1-1. This also is a mdbtools bug: calling SQLGetData on column 4 (TABLE_TYPE) of SQLTables returns SQL_NO_TOTAL in StrLen_or_IndPtr, indicating that there is more data to return, but the driver does not know how much. In this case, it returned all the data, namely "SYSTEM TABLE", so it should set StrLen_or_IndPtr to the length of that (that is, 12).

Cf http://msdn.microsoft.com/en-us/library/ms715441%28v=vs.85%29.aspx
Neither SQL_NO_TOTAL nor zero can be returned on the last valid call to retrieve data from a column, because the application would then have no way of knowing how much of the data in the application buffer is valid.

Revision history for this message
magowiz (magowiz) wrote :

Upstream they say that the issue is on unixodbc package , do I need to create a new bug report here in launchpad about unixodbc ?
The comment in which is said :
https://bugs.freedesktop.org/show_bug.cgi?id=71966#c6

Changed in df-libreoffice:
status: New → Won't Fix
Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

This release of Ubuntu is no longer receiving maintenance updates. If this is still an issue on a maintained version of Ubuntu please let us know.

Changed in libreoffice (Ubuntu):
status: New → Incomplete
Changed in df-libreoffice:
importance: Critical → Unknown
status: Won't Fix → Unknown
Changed in df-libreoffice:
importance: Unknown → Critical
status: Unknown → Won't Fix
Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

This bug has sat incomplete for 6 months. Marking invalid.

Changed in libreoffice (Ubuntu):
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.