Bug report #187

GRASS: Crash when trying to edit a layer where the editor has not sufficient rights

Added by holl-gdf-hannover-de - over 18 years ago. Updated over 15 years ago.

Status:Closed
Priority:Low
Assignee:Redmine Admin
Category:GRASS
Affected QGIS version: Regression?:No
Operating System:Debian Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:10246

Description

Hi developers,

I have found a bug which causes QGIS to crash.
It can be reproduced when you try to edit a layer which is in a different mapset than your current one and where you do not have write-privileges.

A Warning-window pops up and tells you that you are not the owner of the layer, where you can only print 'OK'. After hitting OK, QGIS segfaults.

Here is a gdb-bt:
...
Debug: qgsmaplayer.cpp: 121: (name) QgsMapLayer::name: returning name 'soils_bak
Debug: qgsgrassedit.cpp: 150: (isEditable) layer name: soils_bak
Debug: qgsgrassedit.cpp: 160: (isEditable) Vector layer type: grass
QgsGrassProvider::isGrassEditable
QgsGrassProvider::isValid() returned: true
QgsMapCanvas::drawContents
QgsGrassEdit::~QgsGrassEdit()
QgsGrassEdit::displayDynamic Points = 0 type = 0

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1124519648 (LWP 17647)]
std::_Deque_iterator<QgsPoint, QgsPoint&, QgsPoint*>::operator+= (this=0xbfffe0a0, +n=1) at stl_deque.h:200
200 _M_first = +new_node;
(gdb) bt
#0 std::_Deque_iterator<QgsPoint, QgsPoint&, QgsPoint
>::operator+= (this=0xbfffe0a0, +n=1) at stl_deque.h:200
#3905 0x4168ea3d in QgsRubberBand::reset (this=0x810adc8, isPolygon=false) at stl_deque.h:125
#3906 0x43842813 in QgsGrassEdit::displayDynamic (this=0x8355878, Points=0x0, x=0, y=0, type=0, size=-7549647) at qgsgrassedit.cpp:1673
#3907 0x4384267f in QgsGrassEdit::eraseDynamic (this=0xff8ccd31) at qgsgrassedit.cpp:1644
#3908 0x4383d899 in ~QgsGrassEdit (this=0x8355878) at qgsgrassedit.cpp:923
#3909 0x438156e2 in QgsGrassPlugin::edit (this=0x8138018) at qgsgrassplugin.cpp:451
#3910 0x4393a2e7 in QgsGrassPlugin::qt_metacall (this=0x8138018, _c=InvokeMetaMethod, _id=3, _a=0xbfffe7d8) at qgsgrassplugin.moc.cpp:94
#3911 0x4020dc8f in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#3912 0x4020df55 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#3913 0x406cec3f in QAction::activated () from /usr/lib/libQtGui.so.4
#10 0x406ce4e9 in QAction::activate () from /usr/lib/libQtGui.so.4
#3914 0x4099ea31 in QToolButton::nextCheckState () from /usr/lib/libQtGui.so.4
#3915 0x408f894d in QAbstractButtonPrivate::click () from /usr/lib/libQtGui.so.4
#3916 0x408f9921 in QAbstractButton::mouseReleaseEvent () from /usr/lib/libQtGui.so.4
#3917 0x40716ee2 in QWidget::event () from /usr/lib/libQtGui.so.4
#3918 0x408f9762 in QAbstractButton::event () from /usr/lib/libQtGui.so.4
#3919 0x4099ea66 in QToolButton::event () from /usr/lib/libQtGui.so.4
#3920 0x406d8889 in QApplicationPrivate::notify_helper () from /usr/lib/libQtGui.so.4
#3921 0x406d7427 in QApplication::notify () from /usr/lib/libQtGui.so.4
#3922 0x40728cb8 in QETWidget::translateMouseEvent () from /usr/lib/libQtGui.so.4
#3923 0x40726781 in QApplication::x11ProcessEvent () from /usr/lib/libQtGui.so.4
#3924 0x4073c3a5 in QEventDispatcherX11::processEvents () from /usr/lib/libQtGui.so.4
#3925 0x401fb179 in QEventLoop::processEvents () from /usr/lib/libQtCore.so.4
#3926 0x401fb232 in QEventLoop::exec () from /usr/lib/libQtCore.so.4
#3927 0x401fddc0 in QCoreApplication::exec () from /usr/lib/libQtCore.so.4
#3928 0x406d70e9 in QApplication::exec () from /usr/lib/libQtGui.so.4
#3929 0x0804cb6d in main (argc=1, argv=0xbffff864) at main.cpp:589

Perhaps this is of some help.
Thank you for looking into this.

Best

Stephan

History

#1 Updated by holl-gdf-hannover-de - over 18 years ago

sorry for the unreadble gdb-output. Here it is again

[[QgsGrassEdit]]()
Debug: qgsmaplayer.cpp: 121: (name) [[QgsMapLayer]]::name: returning name 'soils_bak
Debug: qgsgrassedit.cpp: 150: (isEditable) layer name: soils_bak
Debug: qgsgrassedit.cpp: 160: (isEditable) Vector layer type: grass
[[QgsGrassProvider]]::isGrassEditable
[[QgsGrassProvider]]::isValid() returned: true
[[QgsMapCanvas]]::drawContents
[[QgsGrassEdit]]::~QgsGrassEdit()
[[QgsGrassEdit]]::displayDynamic Points = 0 type = 0

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 1124519648 (LWP 17647)]
std::_Deque_iterator<QgsPoint, [[QgsPoint]]&, [[QgsPoint]]*>::operator+= (this=0xbfffe0a0, +n=1) at stl_deque.h:200
200           _M_first = *+new_node;
(gdb) bt
#0  std::_Deque_iterator<QgsPoint, [[QgsPoint]]&, [[QgsPoint]]*>::operator+= (this=0xbfffe0a0, +n=1) at stl_deque.h:200
#3905  0x4168ea3d in [[QgsRubberBand]]::reset (this=0x810adc8, isPolygon=false) at stl_deque.h:125
#3906  0x43842813 in [[QgsGrassEdit]]::displayDynamic (this=0x8355878, Points=0x0, x=0, y=0, type=0, size=-7549647) at qgsgrassedit.cpp:1673
#3907  0x4384267f in [[QgsGrassEdit]]::eraseDynamic (this=0xff8ccd31) at qgsgrassedit.cpp:1644
#3908  0x4383d899 in ~QgsGrassEdit (this=0x8355878) at qgsgrassedit.cpp:923
#3909  0x438156e2 in [[QgsGrassPlugin]]::edit (this=0x8138018) at qgsgrassplugin.cpp:451
#3910  0x4393a2e7 in [[QgsGrassPlugin]]::qt_metacall (this=0x8138018, _c=InvokeMetaMethod, _id=3, _a=0xbfffe7d8) at qgsgrassplugin.moc.cpp:94
#3911  0x4020dc8f in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#3912  0x4020df55 in QMetaObject::activate () from /usr/lib/libQtCore.so.4
#3913  0x406cec3f in QAction::activated () from /usr/lib/libQtGui.so.4
#10 0x406ce4e9 in QAction::activate () from /usr/lib/libQtGui.so.4
#3914 0x4099ea31 in QToolButton::nextCheckState () from /usr/lib/libQtGui.so.4
#3915 0x408f894d in QAbstractButtonPrivate::click () from /usr/lib/libQtGui.so.4
#3916 0x408f9921 in QAbstractButton::mouseReleaseEvent () from /usr/lib/libQtGui.so.4
#3917 0x40716ee2 in QWidget::event () from /usr/lib/libQtGui.so.4
#3918 0x408f9762 in QAbstractButton::event () from /usr/lib/libQtGui.so.4
#3919 0x4099ea66 in QToolButton::event () from /usr/lib/libQtGui.so.4
#3920 0x406d8889 in QApplicationPrivate::notify_helper () from /usr/lib/libQtGui.so.4
#3921 0x406d7427 in QApplication::notify () from /usr/lib/libQtGui.so.4
#3922 0x40728cb8 in QETWidget::translateMouseEvent () from /usr/lib/libQtGui.so.4
#3923 0x40726781 in QApplication::x11ProcessEvent () from /usr/lib/libQtGui.so.4
#3924 0x4073c3a5 in QEventDispatcherX11::processEvents () from /usr/lib/libQtGui.so.4
#3925 0x401fb179 in QEventLoop::processEvents () from /usr/lib/libQtCore.so.4
#3926 0x401fb232 in QEventLoop::exec () from /usr/lib/libQtCore.so.4
#3927 0x401fddc0 in QCoreApplication::exec () from /usr/lib/libQtCore.so.4
#3928 0x406d70e9 in QApplication::exec () from /usr/lib/libQtGui.so.4
#3929 0x0804cb6d in main (argc=1, argv=0xbffff864) at main.cpp:589
(gdb)

#2 Updated by anonymous - over 18 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

Fixed in revision 5685.

Radim

#3 Updated by Anonymous over 15 years ago

Milestone Version 0.8 deleted

Also available in: Atom PDF