Bug report #16385

Project crashes on zooming

Added by Jonathan Webb about 7 years ago. Updated almost 7 years ago.

Status:Closed
Priority:High
Assignee:-
Category:Map Canvas
Affected QGIS version:2.18.4 Regression?:No
Operating System:Linux Mint Easy fix?:No
Pull Request or Patch supplied:No Resolution:not reproducable
Crashes QGIS or corrupts data:Yes Copied to github as #:24294

Description

QGIS 2.18 new install. One particular project crashes out instantly when trying to move the map canvas, or freezes. This is a fairly simple project with about 15 layers, only 5 of which are active.
One layer appears to be problematic - it is a polyline shapefile (saved out of QGIS from a DXF ASCII 2010 that I imported). This is styled by category (about 40 categories) of which maybe 2/3rds are active.

I created a fresh project & added the layers, testing the zoom as they were added and it was stable until I was just putting the finishing touches to the Composer when it started crashing out .

On advice from the OSGEO list, I removed all the plugins & these projects still crash.

GDB/bt report:
gdb -ex=r --args /usr/bin/qgis.bin
GNU gdb (Ubuntu 7.7.1-0ubuntu5~14.04.2) 7.7.1
Copyright (C) 2014 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/&gt;.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/&gt;.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/qgis.bin...(no debugging symbols found)...done.
Starting program: /usr/bin/qgis.bin
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Warning: loading of qgis translation failed [/usr/share/qgis/i18n//qgis_en_GB]
Warning: loading of qt translation failed [/usr/share/qt4/translations/qt_en_GB]
[New Thread 0x7fffcd875700 (LWP 21610)]
[New Thread 0x7fffc7fff700 (LWP 21611)]
[New Thread 0x7fffc75cf700 (LWP 21612)]
[New Thread 0x7fffc6dce700 (LWP 21613)]
Warning: QCss::Parser - Failed to load file "/style.qss"
QInotifyFileSystemWatcherEngine::addPaths: inotify_add_watch failed: No such file or directory
[New Thread 0x7fffc65cd700 (LWP 21615)]
Warning: QFileSystemWatcher: failed to add paths: /home/jonathan/.qgis2//project_templates
[New Thread 0x7fffc5dcc700 (LWP 21616)]
[New Thread 0x7fffc55cb700 (LWP 21617)]
Warning: QLayout: Attempting to add QLayout "" to QgsPanelWidgetStack "mWidgetStack", which already has a layout
[New Thread 0x7fff5e7bc700 (LWP 21636)]
[New Thread 0x7fff5df6d700 (LWP 21642)]
[New Thread 0x7fff5d76c700 (LWP 21643)]
[New Thread 0x7fff5cf6b700 (LWP 21644)]
Warning: QPainter::begin: A paint device can only be painted by one painter at a time.
Warning: QPainter::setRenderHint: Painter must be active to set rendering hints
Warning: QPainter::setBrush: Painter not active
Warning: QPainter::setPen: Painter not active

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fff5df6d700 (LWP 21642)]
0x000001c500000231 in ?? ()
(gdb) bt
#0 0x000001c500000231 in ?? ()
#1 0x00007ffff5086d21 in QPainter::end() ()
from /usr/lib/x86_64-linux-gnu/libQtGui.so.4
#2 0x00007ffff610ddd0 in QgsSimpleMarkerSymbolLayerV2::prepareCache(QgsSymbolV2RenderContext&) () from /usr/lib/libqgis_core.so.2.18.4
#3 0x00007ffff610e34b in QgsSimpleMarkerSymbolLayerV2::startRender(QgsSymbolV2RenderContext&) () from /usr/lib/libqgis_core.so.2.18.4
#4 0x00007ffff6165573 in QgsSymbolV2::startRender(QgsRenderContext&, QgsFields const*) () from /usr/lib/libqgis_core.so.2.18.4
#5 0x00007ffff609bb2c in QgsCategorizedSymbolRendererV2::startRender(QgsRenderContext&, QgsFields const&) () from /usr/lib/libqgis_core.so.2.18.4
#6 0x00007ffff6450e2a in ?? () from /usr/lib/libqgis_core.so.2.18.4
#7 0x00007ffff631a4f7 in QgsMapRendererParallelJob::renderLayerStatic(LayerRenderJob&) () from /usr/lib/libqgis_core.so.2.18.4
#8 0x00007ffff631b7e0 in ?? () from /usr/lib/libqgis_core.so.2.18.4
#9 0x00007ffff631b837 in ?? () from /usr/lib/libqgis_core.so.2.18.4
#10 0x00007ffff631bc1d in ?? () from /usr/lib/libqgis_core.so.2.18.4
#11 0x00007ffff5a93005 in QtConcurrent::ThreadEngineBase::run() ()
from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#12 0x00007ffff5a94fee in ?? () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#13 0x00007ffff5aa132f in ?? () from /usr/lib/x86_64-linux-gnu/libQtCore.so.4
#14 0x00007fffee1e8184 in start_thread (arg=0x7fff5df6d700)
at pthread_create.c:312
---Type <return> to continue, or q <return> to quit---
#15 0x00007ffff458e37d in clone ()
at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111
(gdb)

Associated revisions

Revision fefa572e
Added by Nyall Dawson almost 7 years ago

Fix crash when transform errors occur while rendering

If a transform exception occurred while rendering a symbol then
the QgsSymbolRenderContext cleanup code was never called,
leading to a double delete and crash.

Fixes #16377, #15345, and numerous other crashes seen "in the wild"

Possibly refs #16385

Revision 452c8066
Added by Nyall Dawson almost 7 years ago

Fix crash when transform errors occur while rendering

If a transform exception occurred while rendering a symbol then
the QgsSymbolRenderContext cleanup code was never called,
leading to a double delete and crash.

Fixes #16377, #15345, and numerous other crashes seen "in the wild"

Possibly refs #16385

(cherry-picked from fefa572)

History

#1 Updated by Saber Razmjooei about 7 years ago

This could be related to #16377

#2 Updated by Giovanni Manghi almost 7 years ago

  • Priority changed from Normal to High
  • Status changed from Open to Feedback
  • Description updated (diff)
  • Subject changed from Project crashes on zooming etc to Project crashes on zooming

Saber Razmjooei wrote:

This could be related to #16377

#16377 is likely to be closed because invalid (not replicable on machines different from the reporter one) or already fixed.

#3 Updated by Giovanni Manghi almost 7 years ago

Please attach a sample project/data without that it would be hard to troubleshoot this issue.

#4 Updated by Giovanni Manghi almost 7 years ago

  • Easy fix? set to No
  • Regression? set to No

#5 Updated by Giovanni Manghi almost 7 years ago

  • Resolution set to not reproducable
  • Status changed from Feedback to Closed

Closing for lack of feedback and/or possibly already fixed.

Also available in: Atom PDF