Bug report #3188

Bug in delimited text plugin

Added by Chris Crook almost 10 years ago. Updated almost 10 years ago.

Status:Closed
Priority:Low
Assignee:Jürgen Fischer
Category:C++ Plugins
Affected QGIS version: Regression?:No
Operating System:Windows Easy fix?:No
Pull Request or Patch supplied: Resolution:fixed
Crashes QGIS or corrupts data: Copied to github as #:13248

Description

Accessing attributes in a delimited text file layer causes QGIS to crash.

Steps to repeat.

1. Open QGIS in a new project
1. Select a project CRS with parameters:
+proj=merc +lon_0=0 +lat_ts=0 +x_0=0 +y_0=0 +a=6378137 +b=6378137 +units=m +no_defs

1. Click the delimited text plugin and enter text file: attached file test.txt
layer name: text
delimiter string: \\t, plain characters
X field: x Y field: y
click OK
1. Map should display 3 points
1. Right click layer in the layers list and select "Open attribute table"

QGIS dies with the Windows 'Send error report' dialog.

Operating system: MS Windows XP, service pack 3
QGIS version: 1.6.0 - build 14500

test.txt Magnifier (143 Bytes) Chris Crook, 2010-11-04 11:44 AM

Associated revisions

Revision 6f7786dd
Added by Jürgen Fischer almost 10 years ago

fix #3188

git-svn-id: http://svn.osgeo.org/qgis/trunk/[email protected] c8812cc2-4d05-0410-92ff-de0c093fc19c

Revision eb7b22a2
Added by Jürgen Fischer almost 10 years ago

fix #3188

git-svn-id: http://svn.osgeo.org/qgis/[email protected] c8812cc2-4d05-0410-92ff-de0c093fc19c

History

#1 Updated by Tim Sutton almost 10 years ago

Backtrace from when the crash occurs with the provided sample data:

Debug: /home/timlinux/dev/cpp/qgis/src/app/attributetable/qgsattributetablemodel.cpp: 188: (loadLayer) entered.
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 74: (splitLine) Attempting to split the input line: 50000.00    50000.00    0.01577    0.01914    0.01218 using delimiter     
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 82: (splitLine) Split line into 5 parts
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 74: (splitLine) Attempting to split the input line: 50000.00    60000.00    0.01669    0.02088    0.01301 using delimiter     
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 82: (splitLine) Split line into 5 parts
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 74: (splitLine) Attempting to split the input line: 60000.00    60000.00    0.01563    0.02183    0.01243 using delimiter     
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 82: (splitLine) Split line into 5 parts
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 74: (splitLine) Attempting to split the input line:  using delimiter     
Debug: /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp: 82: (splitLine) Split line into 1 parts
Fatal: ASSERT failure in QList<T>::operator[]: "index out of range", file /usr/include/qt4/QtCore/qlist.h, line 463

Program received signal SIGABRT, Aborted.
0x00007ffff3110ba5 in raise (sig=<value optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
64    ../nptl/sysdeps/unix/sysv/linux/raise.c: No such file or directory.
    in ../nptl/sysdeps/unix/sysv/linux/raise.c

#2 Updated by Tim Sutton almost 10 years ago

Sorry last bt was no use, try again:

#0  0x00007ffff3110ba5 in raise (sig=<value optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#3905  0x00007ffff31146b0 in abort () at abort.c:92
#3906  0x0000000000511cad in myMessageOutput (type=QtFatalMsg, 
    msg=0x1735f38 "ASSERT failure in QList<T>::operator[]: \\"index out of range\\", file /usr/include/qt4/QtCore/qlist.h, line 463")
    at /home/timlinux/dev/cpp/qgis/src/app/main.cpp:241
#3907  0x00007ffff619c80e in qt_message_output(QtMsgType, char const*) () from /usr/lib/libQtCore.so.4
#3908  0x00007ffff619ca42 in ?? () from /usr/lib/libQtCore.so.4
#3909  0x00007ffff619cbf5 in qFatal(char const*, ...) () from /usr/lib/libQtCore.so.4
#3910  0x00000000005530d5 in QList<QString>::operator[] (this=0x7fffffffba30, i=1) at /usr/include/qt4/QtCore/qlist.h:463
#3911  0x00007fffd4c1bd27 in [[QgsDelimitedTextProvider]]::nextFeature (this=0x32e3800, feature=...)
    at /home/timlinux/dev/cpp/qgis/src/providers/delimitedtext/qgsdelimitedtextprovider.cpp:450
#3912  0x00007ffff76556ca in [[QgsVectorLayer]]::nextFeature (this=0x35c1dc0, f=...)
    at /home/timlinux/dev/cpp/qgis/src/core/qgsvectorlayer.cpp:1678
#3913  0x000000000079b9d8 in [[QgsAttributeTableModel]]::loadLayer (this=0x1aa8fe0)
    at /home/timlinux/dev/cpp/qgis/src/app/attributetable/qgsattributetablemodel.cpp:222
#10 0x0000000000799e2e in [[QgsAttributeTableModel]]::QgsAttributeTableModel (this=0x1aa8fe0, theLayer=0x35c1dc0, parent=0x0)
    at /home/timlinux/dev/cpp/qgis/src/app/attributetable/qgsattributetablemodel.cpp:46
#3914 0x00000000007a0971 in [[QgsAttributeTableMemoryModel]]::QgsAttributeTableMemoryModel (this=0x1aa8fe0, theLayer=0x35c1dc0)
    at /home/timlinux/dev/cpp/qgis/src/app/attributetable/qgsattributetablememorymodel.cpp:44
#3915 0x00000000007a1eb3 in [[QgsAttributeTableView]]::setLayer (this=0x32a0f20, layer=0x35c1dc0)
    at /home/timlinux/dev/cpp/qgis/src/app/attributetable/qgsattributetableview.cpp:56
#3916 0x000000000078ee12 in [[QgsAttributeTableDialog]]::QgsAttributeTableDialog (this=0x1aa9610, theLayer=0x35c1dc0, parent=0x0, 
    flags=...) at /home/timlinux/dev/cpp/qgis/src/app/attributetable/qgsattributetabledialog.cpp:66
#3917 0x000000000053f85c in [[QgisApp]]::attributeTable (this=0xefc930) at /home/timlinux/dev/cpp/qgis/src/app/qgisapp.cpp:3847
#3918 0x00000000007faeb8 in [[QgisApp]]::qt_metacall (this=0xefc930, _c=QMetaObject::InvokeMetaMethod, _id=142, _a=0x7fffffffc370)
    at /home/timlinux/dev/cpp/qgis/build/src/app/moc_qgisapp.cxx:479
#3919 0x00007ffff62b0b27 in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/libQtCore.so.4
#3920 0x00007ffff55f8852 in QAction::triggered(bool) () from /usr/lib/libQtGui.so.4
#3921 0x00007ffff55f9f5b in QAction::activate(QAction::ActionEvent) () from /usr/lib/libQtGui.so.4
#3922 0x00007ffff59d957a in ?? () from /usr/lib/libQtGui.so.4
#3923 0x00007ffff59d982c in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/libQtGui.so.4
#3924 0x00007ffff5aa952a in QToolButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/libQtGui.so.4

#3 Updated by Tim Sutton almost 10 years ago

Juergen do you have an idea as to what is causing this?

Regards

Tim

#4 Updated by Jürgen Fischer almost 10 years ago

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

fixed in eb7b22a2 (SVN r14508).

Also available in: Atom PDF