GnuCash
Contact   Instructions
Bug 797811 - GnuCash crashes with segfault when saving to mysql when database already exists
Summary: GnuCash crashes with segfault when saving to mysql when database already exists
Status: RESOLVED FIXED
Alias: None
Product: GnuCash
Classification: Unclassified
Component: Backend - SQL (show other bugs)
Version: 3.10
Hardware: PC Mac OS
: Normal normal
Target Milestone: ---
Assignee: core
QA Contact: core
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-06-19 15:17 EDT by Douglas Mandell
Modified: 2020-06-19 18:23 EDT (History)
3 users (show)

See Also:


Attachments
Crash report (89.30 KB, text/plain)
2020-06-19 15:17 EDT, Douglas Mandell
no flags Details

Description Douglas Mandell 2020-06-19 15:17:53 EDT
Created attachment 373742 [details]
Crash report

I started out using a mysql database on a remote server and got that working. Later, after my computer running GnuCash woke from sleep, GnuCash encountered an error while trying to save to the database, and I successfully saved the data to an XML file on the local machine.

Since I want to keep the data in the remote database, I then used "Save As..." to attempt to save to the database again. After entering the connection information for the mysql database, I got a dialog warning that the database already exists, and asking if I want to replace it. Clicking "Yes" causes GnuCash to crash with a segfault.  Saving to a new empty database works.

This is consistently repeatable.

See attached report.

Also, mysql server is version 5.7.29 running on FreeBSD.
Comment 1 John Ralls 2020-06-19 18:23:33 EDT
I've pushed a fix to maint that should prevent the crash, though there may be other misbehavior from trying to create a database that already exists. The fix will be in 3.906, releasing this weekend, and 4.0 and 3.11 releasing next weekend. Note that there will be no further work on 3.x after the 3.11 release.

Note You need to log in before you can comment on or make changes to this bug.