Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

crash when creating a layer definition file from a memory layer #20265

Closed
qgib opened this issue Jan 27, 2015 · 5 comments
Closed

crash when creating a layer definition file from a memory layer #20265

qgib opened this issue Jan 27, 2015 · 5 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Crash/Data Corruption Project
Milestone

Comments

@qgib
Copy link
Contributor

qgib commented Jan 27, 2015

Author Name: Richard Duivenvoorde (@rduivenvoorde)
Original Redmine Issue: 12064
Affected QGIS version: master
Redmine category:project_loading/saving
Assignee: Jürgen Fischer


100% reproducable with current master:

  • open a new (point) memory layer in QGIS in empty project
  • start editing the layer and add 2 points to it (no styling or whatever)
  • stop/save editing
  • create a layer definition file from it
  • open the layer definition file: full crash

also reopening QGIS and only trying to load the qlr file crashes it

adding a qlr file as attachment


@qgib
Copy link
Contributor Author

qgib commented Feb 5, 2015

Author Name: Nathan Woodrow (@NathanW2)


No crash here on Windows at least.

@qgib
Copy link
Contributor Author

qgib commented Feb 5, 2015

Author Name: Richard Duivenvoorde (@rduivenvoorde)


I will try on another machine, but here with me still crashing: see trace below

Note: I'm loading this in an empty project.

src/core/qgscoordinatereferencesystem.cpp: 1158: (readXML) [1ms] Reading Spatial Ref Sys from xml ------------------------!
src/core/qgscoordinatereferencesystem.cpp: 992: (setMapUnits) [11ms] Projection has linear units of metre
src/core/qgscoordinatereferencesystem.cpp: 1201: (readXML) [0ms] Set from auth id
src/core/qgsvectorlayer.cpp: 1266: (readXml) [1ms] Datasource in QgsVectorLayer::readXml: Point?crs=proj4:+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.417,50.3319,465.552,-0.398957,0.343988,-1.8774,4.0725 +units=m +no_defs
src/core/qgsproviderregistry.cpp: 348: (provider) [0ms] Library name is /home/richard/apps/qgis/master/debug/lib/qgis/plugins/libmemoryprovider.so
src/core/qgscoordinatereferencesystem.cpp: 522: (createFromProj4) [0ms] proj4: +proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.417,50.3319,465.552,-0.398957,0.343988,-1.8774,4.0725 +units=m +no_defs
src/core/qgscoordinatereferencesystem.cpp: 552: (createFromProj4) [1ms] proj string supplied has no +a argument
src/core/qgscoordinatereferencesystem.cpp: 719: (getRecord) [0ms] running query: select * from tbl_srs where parameters='+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.417,50.3319,465.552,-0.398957,0.343988,-1.8774,4.0725 +units=m +no_defs' order by deprecated
src/core/qgscoordinatereferencesystem.cpp: 740: (getRecord) [6ms] trying system srs.db
src/core/qgscoordinatereferencesystem.cpp: 810: (getRecord) [1ms] retrieved:  select * from tbl_srs where parameters='+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +towgs84=565.417,50.3319,465.552,-0.398957,0.343988,-1.8774,4.0725 +units=m +no_defs' order by deprecated
src/core/qgscoordinatereferencesystem.cpp: 673: (createFromProj4) [0ms] proj4string param match search for srsid returned srsid: 2517
src/core/qgscoordinatereferencesystem.cpp: 992: (setMapUnits) [1ms] Projection has linear units of metre
src/core/qgsproviderregistry.cpp: 370: (provider) [0ms] Instantiated the data provider plugin: memory
src/core/qgsvectorlayer.cpp: 1368: (setDataProvider) [0ms] Instantiated the data provider plugin
src/core/qgsvectorlayer.cpp: 1595: (readSymbology) [1ms] calling readXML
src/core/qgslabel.cpp: 731: (readXML) [1ms]  called for layer label properties, got node labelattributes
src/core/qgsmaplayer.cpp: 106: (setLayerName) [0ms] new original name: 'Memory layer'
src/core/qgsmaplayer.cpp: 108: (setLayerName) [0ms] new display name: 'Memory layer'
Fatal: ASSERT: "node->mParent == 0" in file /home/richard/dev/qgis/git/qgis/src/core/layertree/qgslayertreenode.cpp, line 118
Stacktrace (piped through c++filt):
/home/richard/apps/qgis/master/debug/bin/qgis[0x579646]
/home/richard/apps/qgis/master/debug/bin/qgis(myMessageOutput(QtMsgType, char const*)+0x1c3)[0x57990f]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(qt_message_output(QtMsgType, char const*)+0x31)[0x7f947efb86a1]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(+0x71b09)[0x7f947efb8b09]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(qFatal(char const*, ...)+0xa1)[0x7f947efb93f1]
/home/richard/apps/qgis/master/debug/lib/libqgis_core.so.2.7.0(QgsLayerTreeNode::insertChildrenPrivate(int, QList<QgsLayerTreeNode*>)+0x86)[0x7f94807c4fb8]
/home/richard/apps/qgis/master/debug/lib/libqgis_core.so.2.7.0(QgsLayerTreeGroup::insertChildNodes(int, QList<QgsLayerTreeNode*>)+0x3c)[0x7f94807afa8c]
/home/richard/apps/qgis/master/debug/lib/libqgis_core.so.2.7.0(QgsLayerDefinition::loadLayerDefinition(QDomDocument, QgsLayerTreeGroup*, QString&)+0x57d)[0x7f948088ffc5]
/home/richard/apps/qgis/master/debug/lib/libqgis_core.so.2.7.0(QgsLayerDefinition::loadLayerDefinition(QString const&, QgsLayerTreeGroup*, QString&)+0x19b)[0x7f948088f961]
/home/richard/apps/qgis/master/debug/bin/qgis(QgisApp::openLayerDefinition(QString const&)+0x40)[0x5a3ada]
/home/richard/apps/qgis/master/debug/bin/qgis(QgisApp::addLayerDefinition()+0xe8)[0x59705c]
/home/richard/apps/qgis/master/debug/bin/qgis[0x96218e]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(QMetaObject::activate(QObject*, QMetaObject const*, int, void**)+0x32c)[0x7f947f0e1f4c]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QAction::triggered(bool)+0x42)[0x7f947e41aaf2]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QAction::activate(QAction::ActionEvent)+0x87)[0x7f947e41c677]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(+0x615ead)[0x7f947e86fead]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(+0x61a869)[0x7f947e874869]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QWidget::event(QEvent*)+0x298)[0x7f947e4744d8]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QMenu::event(QEvent*)+0x6b)[0x7f947e87883b]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QApplicationPrivate::notify_helper(QObject*, QEvent*)+0x8c)[0x7f947e42129c]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QApplication::notify(QObject*, QEvent*)+0x41f)[0x7f947e427f0f]
/home/richard/apps/qgis/master/debug/lib/libqgis_core.so.2.7.0(QgsApplication::notify(QObject*, QEvent*)+0xb3)[0x7f94807ccca7]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(QCoreApplication::notifyInternal(QObject*, QEvent*)+0x8d)[0x7f947f0ccf8d]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool)+0x15f)[0x7f947e42756f]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(+0x24443a)[0x7f947e49e43a]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(QApplication::x11ProcessEvent(_XEvent*)+0x60c)[0x7f947e49ca9c]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(+0x26bad2)[0x7f947e4c5ad2]
/lib/x86_64-linux-gnu/libglib-2.0.so.0(g_main_context_dispatch+0x24d)[0x7f9479ba7c5d]
/lib/x86_64-linux-gnu/libglib-2.0.so.0(+0x49f48)[0x7f9479ba7f48]
/lib/x86_64-linux-gnu/libglib-2.0.so.0(g_main_context_iteration+0x2c)[0x7f9479ba7ffc]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>)+0x5d)[0x7f947f0fc4ed]
/usr/lib/x86_64-linux-gnu/libQtGui.so.4(+0x26bb96)[0x7f947e4c5b96]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>)+0x41)[0x7f947f0cbae1]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>)+0x1a5)[0x7f947f0cbe45]
/usr/lib/x86_64-linux-gnu/libQtCore.so.4(QCoreApplication::exec()+0x99)[0x7f947f0d18b9]
/home/richard/apps/qgis/master/debug/bin/qgis(main+0x315d)[0x57cace]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf5)[0x7f947b9e2b45]
/home/richard/apps/qgis/master/debug/bin/qgis[0x5790e9]
/usr/local/bin/qgis: line 6: 30332 Aborted                 /home/richard/apps/qgis/master/debug/bin/qgis "$@"

@qgib
Copy link
Contributor Author

qgib commented Feb 9, 2015

Author Name: Jürgen Fischer (@jef-n)


Richard Duivenvoorde wrote:

I will try on another machine, but here with me still crashing: see trace below

Note: I'm loading this in an empty project.

[...]

you're loading a memory layer from a qlr?


  • status_id was changed from Open to Feedback
  • category_id was configured as Project Loading/Saving

@qgib
Copy link
Contributor Author

qgib commented Feb 9, 2015

Author Name: Jürgen Fischer (@jef-n)


  • assigned_to_id was changed from Nathan Woodrow to Jürgen Fischer

@qgib
Copy link
Contributor Author

qgib commented Feb 9, 2015

Author Name: Jürgen Fischer (@jef-n)


Fixed in changeset "ee50520a52e6ce543c5c95743d28fed50b636eae".


  • status_id was changed from Feedback to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Project Crash/Data Corruption labels May 25, 2019
@qgib qgib added this to the Version 2.8 milestone May 25, 2019
@qgib qgib closed this as completed May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Crash/Data Corruption Project
Projects
None yet
Development

No branches or pull requests

1 participant