]> source.dussan.org Git - tigervnc.git/commitdiff
[Bugfix] Don't hook pixmaps in vncHooks, it fixes crash after XDrawArc call.
authorAdam Tkac <atkac@redhat.com>
Wed, 8 Dec 2010 14:43:55 +0000 (14:43 +0000)
committerAdam Tkac <atkac@redhat.com>
Wed, 8 Dec 2010 14:43:55 +0000 (14:43 +0000)
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4220 3789f03b-4d11-0410-bbf8-ca57d06f2519

unix/xserver/hw/vnc/vncHooks.cc

index c9a9abf92a41474e0579e29816135b04ba3830c3..1f928505375057a459f1530be80607e081f0c05d 100644 (file)
@@ -625,7 +625,7 @@ public:
 };
 
 
-// ValidateGC - wrap the "ops" if a drawable window or pixmap
+// ValidateGC - wrap the "ops" if a viewable window
 
 static void vncHooksValidateGC(GCPtr pGC, unsigned long changes,
                                DrawablePtr pDrawable)
@@ -637,7 +637,7 @@ static void vncHooksValidateGC(GCPtr pGC, unsigned long changes,
   (*pGC->funcs->ValidateGC) (pGC, changes, pDrawable);
 
   u.vncHooksGC->wrappedOps = 0;
-  if (pDrawable->type == DRAWABLE_WINDOW || pDrawable->type == DRAWABLE_PIXMAP) {
+  if (pDrawable->type == DRAWABLE_WINDOW && ((WindowPtr) pDrawable)->viewable) {
     u.vncHooksGC->wrappedOps = pGC->ops;
     DBGPRINT((stderr,"vncHooksValidateGC: wrapped GC ops\n"));
   }