Bug report #7006
New core QgsOfflineEditingPlugin crashing app on exit
Status: | Closed | ||
---|---|---|---|
Priority: | Severe/Regression | ||
Assignee: | - | ||
Category: | C++ Plugins | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | Mac | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | Yes | Copied to github as #: | 16106 |
Description
On Mac, I get a EXC_BAD_ACCESS crash from the new moved-to-core QgsOfflineEditingPlugin when exiting QGIS.
See attached crash report of relevant info.
Associated revisions
fix #7006 (if you actually use it)
History
#1 Updated by Mathias Walker almost 12 years ago
Can you try removing
delete mProgressDialog;
in QgsOfflineEditingPlugin::~QgsOfflineEditingPlugin()
on line 49 of src/plugins/offline_editing/offline_editing_plugin.cpp
?
#2 Updated by Larry Shaffer almost 12 years ago
- Status changed from Open to In Progress
Yes, removing:
delete mProgressDialog;
does work, i.e., no more crash. Thanks.
#3 Updated by Jürgen Fischer almost 12 years ago
- Status changed from In Progress to Closed
Fixed in changeset 4cd9b8fd781c77ddd06918fc2e609d8dffbc1697.
#4 Updated by Larry Shaffer almost 12 years ago
- Status changed from Closed to Reopened
Hi Juergen,
That doesn't quite do it (though I thought it should). I still get the same destructor error. If I change the following (at line 74):
mProgressDialog = new QgsOfflineEditingProgressDialog( mQGisIface->mainWindow(), QgisGui::ModalDialogFlags );
to
mProgressDialog = new QgsOfflineEditingProgressDialog( 0, QgisGui::ModalDialogFlags );
all works well. I believe this is where the issue stems from. I tested the plugin with QgsOfflineEditingProgressDialog having no parent and it worked fine. Question is: when the plugin was moved into core, does mQGisIface->mainWindow() get deleted before or after the plugin?
It would be best for the dialog to have an app-based widget as a parent, so that the app's stylesheet can be inherited. What should be the dialog's parent in that case?
#5 Updated by Jürgen Fischer almost 12 years ago
- Status changed from Reopened to Closed
Fixed in changeset 8d063fb6bd939437eca55bdd53db3364631c0b73.