Bug report #11455

Crash when setting transparency for WMS layer

Added by Gary Sherman over 9 years ago. Updated over 9 years ago.

Status:Closed
Priority:Severe/Regression
Assignee:Martin Dobias
Category:Web Services clients/WMS
Affected QGIS version:2.4.0 Regression?:No
Operating System:OS X Easy fix?:No
Pull Request or Patch supplied:No Resolution:
Crashes QGIS or corrupts data:Yes Copied to github as #:19731

Description

QGIS crashes after repeatedly adjusting the transparency for a WMS layer (tested with raster source layers). Sometimes it crashes first time or it may take several times.

Tested with master build 697ebff on both OSX (crashed) and Linux (no crash).

Seems to be an OS X related issue.

issue11455_ok-here.png (676 KB) Larry Shaffer, 2014-10-23 03:59 PM

Associated revisions

Revision c9e05f98
Added by Martin Dobias over 9 years ago

Fix #11455 (Crash when setting transparency for WMS layer)

Layer transparency instance was not copied when renderers were cloned.

Revision 691f4a28
Added by Martin Dobias over 9 years ago

Fix #11455 take two (raster crashes)

Thanks to Nyall for pointing this out

History

#1 Updated by Martin Dobias over 9 years ago

Hi Gary - is it possible to have a backtrace? When does the crash happen - during rendering or while changing the transparency in GUI?

#2 Updated by Martin Dobias over 9 years ago

  • Status changed from Open to Feedback

#3 Updated by Gary Sherman over 9 years ago

The crash happens after setting transparency and closing the dialog---so during rendering (nothing is drawn on the canvas).

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: 13 at address: 0x0000000000000000
[Switching to process 42633 thread 0x7317]
0x0000000104483b62 in QgsRasterTransparency::isEmpty ()
(gdb) bt
#0 0x0000000104483b62 in QgsRasterTransparency::isEmpty ()
#1 0x000000010449370c in QgsRasterRenderer::usesTransparency ()
#2 0x000000010449a569 in QgsSingleBandColorDataRenderer::block ()
#3 0x000000010449cb78 in QgsBrightnessContrastFilter::block ()
#4 0x000000010449d56b in QgsHueSaturationFilter::block ()
#5 0x00000001044907b7 in QgsRasterResampleFilter::block ()
#6 0x000000010446e75a in QgsRasterProjector::block ()
#7 0x00000001044760f7 in QgsRasterIterator::readNextRasterPart ()
#8 0x0000000104489038 in QgsRasterDrawer::draw ()
#9 0x0000000104482ca6 in QgsRasterLayerRenderer::render ()
#10 0x00000001042cdbad in QgsMapRendererCustomPainterJob::doRender ()
#11 0x00000001042cdc2b in QgsMapRendererCustomPainterJob::staticRender ()
#12 0x0000000100352fd5 in QtConcurrent::RunFunctionTask<void>::run ()
#13 0x0000000104eda4bb in QThreadPoolThread::run ()
#14 0x0000000104ee7f74 in QThreadPrivate::start ()
#15 0x00007fff92aef772 in _pthread_start ()
#16 0x00007fff92adc1a1 in thread_start ()

#4 Updated by Martin Dobias over 9 years ago

  • Assignee set to Martin Dobias

#5 Updated by Martin Dobias over 9 years ago

  • Status changed from Feedback to Closed

#6 Updated by Martin Dobias over 9 years ago

I couldn't get my QGIS to crash (linux), but I suppose I have caught the bug that was biting you...

#7 Updated by Gary Sherman over 9 years ago

Now crashes when double-clicking the WMS layer. I'm waiting for the nightly OSX build to test it rather than my local build.

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: 13 at address: 0x0000000000000000
0x00000001054090fb in QPainterPrivate::attachPainterPrivate ()
(gdb) bt
#0 0x00000001054090fb in QPainterPrivate::attachPainterPrivate ()
#1 0x000000010540a13a in QPainter::QPainter ()
#2 0x0000000112a7ce16 in QgsWmsImageDownloadHandler::cacheReplyFinished ()
#3 0x000000010501f1ee in QMetaObject::activate ()
#4 0x0000000105f75f46 in QNetworkReplyImplPrivate::finished ()
#5 0x0000000105ff2800 in QNetworkAccessHttpBackend::qt_static_metacall ()
#6 0x000000010501b711 in QObject::event ()
#7 0x00000001052c69ed in QApplicationPrivate::notify_helper ()
#8 0x00000001052cd064 in QApplication::notify ()
#9 0x00000001041f65a7 in QgsApplication::notify ()
#10 0x000000010500720c in QCoreApplication::notifyInternal ()
#11 0x0000000105008620 in QCoreApplicationPrivate::sendPostedEvents ()
#12 0x00007fff931a3b31 in CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION ()
#13 0x00007fff931a3455 in __CFRunLoopDoSources0 ()
#14 0x00007fff931c67f5 in __CFRunLoopRun ()
#15 0x00007fff931c60e2 in CFRunLoopRunSpecific ()
#16 0x00007fff951e1eb4 in RunCurrentEventLoopInMode ()
#17 0x00007fff951e1c52 in ReceiveNextEventCommon ()
#18 0x00007fff951e1ae3 in BlockUntilNextEventMatchingListInMode ()
#19 0x00007fff8e8ef533 in _DPSNextEvent ()
#20 0x00007fff8e8eedf2 in -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] ()
#21 0x000000010527f5ed in QEventDispatcherMac::processEvents ()
#22 0x0000000105006114 in QEventLoop::processEvents ()
#23 0x00000001050064c4 in QEventLoop::exec ()
#24 0x0000000112a5d96d in QgsWmsProvider::draw ()
#25 0x0000000112a5dcf8 in QgsWmsProvider::readBlock ()
#26 0x000000010446c09d in QgsRasterDataProvider::block ()
#27 0x000000010449e30d in QgsSingleBandColorDataRenderer::block ()
#28 0x00000001044a0a18 in QgsBrightnessContrastFilter::block ()
#29 0x00000001044a140b in QgsHueSaturationFilter::block ()
#30 0x0000000104494437 in QgsRasterResampleFilter::block ()
#31 0x00000001044723da in QgsRasterProjector::block ()
#32 0x0000000104479d77 in QgsRasterIterator::readNextRasterPart ()
#33 0x000000010448ccb8 in QgsRasterDrawer::draw ()
#34 0x000000010447c8ac in QgsRasterLayer::draw ()
#35 0x00000001044824a6 in QgsRasterLayer::previewAsPixmap ()
#36 0x0000000100213177 in QgsRasterLayerProperties::sync ()
#37 0x0000000100210e39 in QgsRasterLayerProperties::QgsRasterLayerProperties ()
#38 0x000000010003cd33 in QgisApp::showLayerProperties ()
#39 0x000000010000e17b in QgisApp::layerTreeViewDoubleClicked ()
#40 0x000000010035403e in QgisApp::qt_static_metacall ()
#41 0x000000010501f1ee in QMetaObject::activate ()
#42 0x00000001057c54e9 in QAbstractItemView::doubleClicked ()
#43 0x00000001058170af in QTreeView::mouseDoubleClickEvent ()
#44 0x000000010532336f in QWidget::event ()
#45 0x00000001056b28ec in QFrame::event ()
#46 0x000000010573ebc7 in QAbstractScrollArea::viewportEvent ()
#47 0x00000001057d3ccb in QAbstractItemView::viewportEvent ()
#48 0x0000000105812c0b in QTreeView::viewportEvent ()
#49 0x0000000105740f50 in QAbstractScrollAreaFilter::eventFilter ()
#50 0x0000000105006cb7 in QCoreApplicationPrivate::sendThroughObjectEventFilters ()
#51 0x00000001052c69be in QApplicationPrivate::notify_helper ()
#52 0x00000001052cd590 in QApplication::notify ()
#53 0x00000001041f65a7 in QgsApplication::notify ()
#54 0x000000010500720c in QCoreApplication::notifyInternal ()
#55 0x00000001052cafdd in QApplicationPrivate::sendMouseEvent ()
#56 0x000000010527aacb in qt_mac_handleMouseEvent ()
#57 0x00007fff8e9d450e in -[NSWindow sendEvent:] ()
#58 0x000000010526fbb7 in -[QCocoaWindow sendEvent:] ()
#59 0x00007fff8e9d0644 in -[NSApplication sendEvent:] ()
#60 0x0000000105274bf4 in -[QNSApplication sendEvent:] ()
#61 0x00007fff8e8e621a in -[NSApplication run] ()
#62 0x000000010527fa80 in QEventDispatcherMac::processEvents ()
#63 0x0000000105006114 in QEventLoop::processEvents ()
#64 0x00000001050064c4 in QEventLoop::exec ()
#65 0x0000000105008bac in QCoreApplication::exec ()
#66 0x000000010000d384 in main ()
(gdb)

#8 Updated by Giovanni Manghi over 9 years ago

  • Status changed from Closed to Reopened

#9 Updated by Martin Dobias over 9 years ago

  • Status changed from Reopened to Closed

#10 Updated by Martin Dobias over 9 years ago

Gary, please try again - the first "fix" has obviously broken more stuff than it has fixed

#11 Updated by Gary Sherman over 9 years ago

No change since my last report. I used the nightly build to test which includes the changeset. It would be nice to get confirmation of this issue from someone else on MacOS

#12 Updated by Denis Rouzaud over 9 years ago

Just tested on mac with master (Debug build type), and I can't reproduce.

I added a WMS layer, changed the transparency 3 times without any troubles.

#13 Updated by Gary Sherman over 9 years ago

Please try with this source just to be sure:
http://wms.alaskamapped.org/extras?

DRGs Hill Shaded Without Scale Limits, drg_63k_shaded_no_limits

#14 Updated by ramon . over 9 years ago

I can't replicate it with this set up and the layer mentioned above :
Macos 1.7.5
QGIS nightly build aeb9d93 from dakotacarto.

#15 Updated by Larry Shaffer over 9 years ago

Hi Gary,

I tried with my main master build (built off of pure Homebrew dependencies setup), and just tested with latest nightly (built off of Kyngchaos.com frameworks, etc.). With both builds, I could not cause a crash. I changed the transparency of the noted WMS layer (drg_63k_shaded_no_limits from http://wms.alaskamapped.org/extras) about twenty times each time I tested.

I also tried other WMS layers from that server, layered over top of each other. Still no crash on transparency change.

This is on Mac OS X 10.9.5, fully updated.

Any other possible variable in your setup that we can try to reproduce this issue locally?

#16 Updated by Gary Sherman over 9 years ago

OS X 10.8 here---must be something local to my machine, although I have no idea what. I do have several versions of QGIS installed, but not sure that is an issue. I guess it's a non-blocker except for me :)

Thanks all for testing---leave it closed unless someone else can replicate it...

Also available in: Atom PDF