[rkward-cvs] SF.net SVN: rkward-code:[4846] trunk/rkward/rkward/rbackend/rkwarddevice/ rkgraphicsdevice.cpp

tfry at users.sf.net tfry at users.sf.net
Sun Sep 28 16:49:46 UTC 2014


Revision: 4846
          http://sourceforge.net/p/rkward/code/4846
Author:   tfry
Date:     2014-09-28 16:49:45 +0000 (Sun, 28 Sep 2014)
Log Message:
-----------
Fix potential crash while closing graphics window

Modified Paths:
--------------
    trunk/rkward/rkward/rbackend/rkwarddevice/rkgraphicsdevice.cpp

Modified: trunk/rkward/rkward/rbackend/rkwarddevice/rkgraphicsdevice.cpp
===================================================================
--- trunk/rkward/rkward/rbackend/rkwarddevice/rkgraphicsdevice.cpp	2014-09-26 18:04:39 UTC (rev 4845)
+++ trunk/rkward/rkward/rbackend/rkwarddevice/rkgraphicsdevice.cpp	2014-09-28 16:49:45 UTC (rev 4846)
@@ -2,7 +2,7 @@
                           rkgraphicsdevice_backendtransmitter  -  description
                              -------------------
     begin                : Mon Mar 18 20:06:08 CET 2013
-    copyright            : (C) 2013 by Thomas Friedrichsmeier 
+    copyright            : (C) 2013, 2014 by Thomas Friedrichsmeier 
     email                : tfry at users.sourceforge.net
  ***************************************************************************/
 
@@ -79,6 +79,7 @@
 }
 
 void RKGraphicsDevice::updateNow () {
+	if (!view) return;	// device windows already killed, but this instance not yet removed.
 	if (painter.isActive ()) painter.end ();
 #ifdef USE_QIMAGE_BUFFER
 	view->setPixmap (QPixmap::fromImage (area));





More information about the rkward-tracker mailing list