Bug report #1241
SPIT & Identify Features crashes
Status: | Closed | ||
---|---|---|---|
Priority: | Low | ||
Assignee: | nobody - | ||
Category: | Vectors | ||
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 #: | 11301 |
Description
After the recent changes to Postgres stuff QGIS (r9120) crashes when using SPIT. The crash seems to originate in '/usr/lib/libQtCore.so.4'. Can QGIS do anything about it or is it all due to some QT bug?
PostgreSQL 8.2.7, PostGIS 1.3.3, QT 4.4.0 (all stock repository packages) on Debian testing amd64.
Sample shapefile attached.
1. start SPIT
2. connect to database
3. select public schema
4. select shapefile
5. OK - crash:
Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7f32afb7a7a0 (LWP 13164)] 0x00007f32aeff852c in ?? () from /usr/lib/libQtCore.so.4 (gdb) bt #0 0x00007f32aeff852c in ?? () from /usr/lib/libQtCore.so.4 #3905 0x00007f32aeff892d in QString::arg () from /usr/lib/libQtCore.so.4 #3906 0x00007f329b0bbeeb in [[QgsShapeFile]]::insertLayer (this=0x1fe99d0, dbname= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 2628}, alloc = 0, size = 0, data = 0x9537ba, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f32af38685a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fffb7cb3e80, static codecForCStrings = 0x0}, schema= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 2628}, alloc = 0, size = 0, data = 0x9537ba, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f32af38685a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fffb7cb3e70, static codecForCStrings = 0x0}, primary_key= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 2628}, alloc = 0, size = 0, data = 0x9537ba, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f32af38685a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fffb7cb3e60, static codecForCStrings = 0x0}, geom_col= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 2628}, alloc = 0, size = 0, data = 0x9537ba, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f32af38685a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fffb7cb3e50, static codecForCStrings = 0x0}, srid= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 2628}, alloc = 0, size = 0, data = 0x9537ba, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f32af38685a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fffb7cb3e40, static codecForCStrings = 0x0}, conn=0x1ed43b0, pro=@0x7fffb7cb2ef0, fin=@0x7fffb7cb306f, errorText=@0x7fffb7cb2fd0) at /home/shoofi/src/straight/qgis-trunk/src/plugins/spit/qgsshapefile.cpp:283 #3907 0x00007f329b0a59a6 in [[QgsSpit]]::import (this=0x1e8bca0) at /home/shoofi/src/straight/qgis-trunk/src/plugins/spit/qgsspit.cpp:771 #3908 0x00007f329b0c2f49 in [[QgsSpit]]::on_buttonBox_accepted (this=0x1e8bca0) at /home/shoofi/src/straight/qgis-trunk/build/src/plugins/spit/../../../../src/plugins/spit/qgsspit.h:84 #3909 0x00007f329b0c2caf in [[QgsSpit]]::qt_metacall (this=0x1e8bca0, _c=QMetaObject::InvokeMetaMethod, _id=4, _a=0x7fffb7cb4220) at /home/shoofi/src/straight/qgis-trunk/build/src/plugins/spit/moc_qgsspit.cxx:90 #3910 0x00007f32af0b3764 in QMetaObject::activate () from /usr/lib/libQtCore.so.4 #3911 0x00007f32ae902221 in QDialogButtonBox::qt_metacall () from /usr/lib/libQtGui.so.4 #3912 0x00007f32af0b3764 in QMetaObject::activate () from /usr/lib/libQtCore.so.4 #3913 0x00007f32aeb4c6e7 in QAbstractButton::clicked () from /usr/lib/libQtGui.so.4 #10 0x00007f32ae8d253b in ?? () from /usr/lib/libQtGui.so.4 #3914 0x00007f32ae8d4082 in ?? () from /usr/lib/libQtGui.so.4 #3915 0x00007f32ae8d42d5 in QAbstractButton::mouseReleaseEvent () from /usr/lib/libQtGui.so.4 #3916 0x00007f32ae6203af in QWidget::event () from /usr/lib/libQtGui.so.4 #3917 0x00007f32ae5cde5d in QApplicationPrivate::notify_helper () from /usr/lib/libQtGui.so.4 #3918 0x00007f32ae5d639a in QApplication::notify () from /usr/lib/libQtGui.so.4 #3919 0x00007f32af09f411 in QCoreApplication::notifyInternal () from /usr/lib/libQtCore.so.4 #3920 0x00007f32ae5d5738 in QApplicationPrivate::sendMouseEvent () from /usr/lib/libQtGui.so.4 #3921 0x00007f32ae639719 in ?? () from /usr/lib/libQtGui.so.4 #3922 0x00007f32ae6385ef in QApplication::x11ProcessEvent () from /usr/lib/libQtGui.so.4 #3923 0x00007f32ae65f9cc in ?? () from /usr/lib/libQtGui.so.4 #3924 0x00007f32ab168892 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0 #3925 0x00007f32ab16c01d in ?? () from /usr/lib/libglib-2.0.so.0 #3926 0x00007f32ab16c1db in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0 #3927 0x00007f32af0c783f in QEventDispatcherGlib::processEvents () from /usr/lib/libQtCore.so.4 #3928 0x00007f32ae65f16f in ?? () from /usr/lib/libQtGui.so.4 #3929 0x00007f32af09dd22 in QEventLoop::processEvents () from /usr/lib/libQtCore.so.4 #3930 0x00007f32af09dead in QEventLoop::exec () from /usr/lib/libQtCore.so.4 #3931 0x00007f32af0a037d in QCoreApplication::exec () from /usr/lib/libQtCore.so.4 #3932 0x00000000004bc63a in main (argc=1, argv=0x7fffb7cb6108) at /home/shoofi/src/straight/qgis-trunk/src/app/main.cpp:684 (gdb)
History
#1 Updated by John Tull about 16 years ago
I just tested on my system and was able to add a shapefile to my postgis. Tried with your sample file and it also worked. OS X 10.5.4, Qt4.4.1, postgis 1.3.3. Using revision 9120 of qgis.
#2 Updated by Jürgen Fischer about 16 years ago
not reproducable here either, but I fixed a spit bug in c05bfb54 (SVN r9169). Does that help here too?
#3 Updated by Maciej Sieczka - about 16 years ago
Replying to [comment:2 jef]:
not reproducable here either, but I fixed a spit bug in c05bfb54 (SVN r9169). Does that help here too?
Nope. Still crashes in 8520ec52 (SVN r9174). The backtrace slightly changed:
Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7f901a5847a0 (LWP 24529)] 0x00007f90199b152c in ?? () from /usr/lib/libQtCore.so.4 (gdb) bt #0 0x00007f90199b152c in ?? () from /usr/lib/libQtCore.so.4 #3905 0x00007f90199b192d in QString::arg () from /usr/lib/libQtCore.so.4 #3906 0x00007f9005809dcb in [[QgsShapeFile]]::insertLayer (this=0x3144440, dbname= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 3117}, alloc = 0, size = 0, data = 0x92f33a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f9019d3f85a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fff226bb720, static codecForCStrings = 0x0}, schema= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 3117}, alloc = 0, size = 0, data = 0x92f33a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f9019d3f85a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fff226bb710, static codecForCStrings = 0x0}, primary_key= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 3117}, alloc = 0, size = 0, data = 0x92f33a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f9019d3f85a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fff226bb700, static codecForCStrings = 0x0}, geom_col= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 3117}, alloc = 0, size = 0, data = 0x92f33a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f9019d3f85a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fff226bb6f0, static codecForCStrings = 0x0}, srid= {static null = {<No data fields>}, static shared_null = {ref = {_q_value = 3117}, alloc = 0, size = 0, data = 0x92f33a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, static shared_empty = {ref = {_q_value = 53}, alloc = 0, size = 0, data = 0x7f9019d3f85a, clean = 0, simpletext = 0, righttoleft = 0, asciiCache = 0, capacity = 0, reserved = 0, array = {0}}, d = 0x7fff226bb6e0, static codecForCStrings = 0x0}, conn=0x3ee7ce0, pro=@0x7fff226ba790, fin=@0x7fff226ba90f, errorText=@0x7fff226ba870) at /home/shoofi/src/straight/qgis-trunk/src/plugins/spit/qgsshapefile.cpp:301 #3907 0x00007f90057f3886 in [[QgsSpit]]::import (this=0x1a02230) at /home/shoofi/src/straight/qgis-trunk/src/plugins/spit/qgsspit.cpp:772 #3908 0x00007f9005810f35 in [[QgsSpit]]::on_buttonBox_accepted (this=0x1a02230) at /home/shoofi/src/straight/qgis-trunk/build/src/plugins/spit/../../../../src/plugins/spit/qgsspit.h:84 #3909 0x00007f9005810c9b in [[QgsSpit]]::qt_metacall (this=0x1a02230, _c=QMetaObject::InvokeMetaMethod, _id=4, _a=0x7fff226bbac0) at /home/shoofi/src/straight/qgis-trunk/build/src/plugins/spit/moc_qgsspit.cxx:90 #3910 0x00007f9019a6c764 in QMetaObject::activate () from /usr/lib/libQtCore.so.4 #3911 0x00007f90192bb221 in QDialogButtonBox::qt_metacall () from /usr/lib/libQtGui.so.4 #3912 0x00007f9019a6c764 in QMetaObject::activate () from /usr/lib/libQtCore.so.4 #3913 0x00007f90195056e7 in QAbstractButton::clicked () from /usr/lib/libQtGui.so.4 #10 0x00007f901928b53b in ?? () from /usr/lib/libQtGui.so.4 #3914 0x00007f901928d082 in ?? () from /usr/lib/libQtGui.so.4 #3915 0x00007f901928d2d5 in QAbstractButton::mouseReleaseEvent () from /usr/lib/libQtGui.so.4 #3916 0x00007f9018fd93af in QWidget::event () from /usr/lib/libQtGui.so.4 #3917 0x00007f9018f86e5d in QApplicationPrivate::notify_helper () from /usr/lib/libQtGui.so.4 #3918 0x00007f9018f8f39a in QApplication::notify () from /usr/lib/libQtGui.so.4 #3919 0x00007f9019a58411 in QCoreApplication::notifyInternal () from /usr/lib/libQtCore.so.4 #3920 0x00007f9018f8e738 in QApplicationPrivate::sendMouseEvent () from /usr/lib/libQtGui.so.4 #3921 0x00007f9018ff2719 in ?? () from /usr/lib/libQtGui.so.4 #3922 0x00007f9018ff15ef in QApplication::x11ProcessEvent () from /usr/lib/libQtGui.so.4 #3923 0x00007f90190189cc in ?? () from /usr/lib/libQtGui.so.4 #3924 0x00007f9015b21892 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0 #3925 0x00007f9015b2501d in ?? () from /usr/lib/libglib-2.0.so.0 #3926 0x00007f9015b251db in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0 #3927 0x00007f9019a8083f in QEventDispatcherGlib::processEvents () from /usr/lib/libQtCore.so.4 #3928 0x00007f901901816f in ?? () from /usr/lib/libQtGui.so.4 #3929 0x00007f9019a56d22 in QEventLoop::processEvents () from /usr/lib/libQtCore.so.4 #3930 0x00007f9019a56ead in QEventLoop::exec () from /usr/lib/libQtCore.so.4 #3931 0x00007f9019a5937d in QCoreApplication::exec () from /usr/lib/libQtCore.so.4 #3932 0x00000000004b1829 in main (argc=1, argv=0x7fff226bdb18) at /home/shoofi/src/straight/qgis-trunk/src/app/main.cpp:683 (gdb)
#4 Updated by Gabriele Monfardini about 16 years ago
I've exactly the same problem on qgis 0.11, postgreSQL 8.1, POSTGIS="1.1.6" GEOS="2.2.3-CAPI-1.1.1" PROJ="Rel. 4.4.9, 29 Oct 2004" on Ubuntu Hardy amd64, on every shapefile
#5 Updated by Maciej Sieczka - about 16 years ago
I just had an exactly the same backtrace after a crash during querying a shapefile with Identify Features tool.
This seems a bug somewhere deep in QGIS, or a QT 4.4.0 bug.
#6 Updated by Brendon Wolff-Piggott - almost 16 years ago
Replying to [comment:5 msieczka]:
I just had an exactly the same backtrace after a crash during querying a shapefile with Identify Features tool.
This seems a bug somewhere deep in QGIS, or a QT 4.4.0 bug.
Imported shape files successfully to QGIS 1.0.0 Preview 2 with PostgreSQL 8.3 on Ubuntu 8.04. Using the provided shape file I get:
"Problem inserting features from file:
/home/workshop/Desktop/buffer1.shp
The database gave an error while executing this SQL:
CREATE TABLE ""."buffer1"("gid" int4 PRIMARY KEY,"CAT" float,"NAZWA" varchar(80) )
The error was:
ro-length delimited identifier at or near """"
LINE 1: CREATE TABLE ""."buffer1"("gid" int4 PRIMARY KEY,"CAT" float..."
^
#7 Updated by Jürgen Fischer almost 16 years ago
- Status changed from Open to Closed
- Resolution set to fixed
fixed in f6bda8b0 (SVN r10095)
#8 Updated by Anonymous about 15 years ago
Milestone Version 1.0.1 deleted