classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cp-patches] fix GdkGraphics2D segfault


From: Andreas Tobler
Subject: Re: [cp-patches] fix GdkGraphics2D segfault
Date: Sat, 01 Oct 2005 00:10:54 +0200
User-agent: Mozilla Thunderbird 1.0.5 (Macintosh/20050711)

Hi all,

I commited this one since I feel it goes under obvious. If you do not think so, I'll revert asap.

I wanted to ask Tom for official approval. But I did not reach him. He gave me offline confirmation that this is a bug.

Andreas


Andreas Tobler wrote:
Hi all,

this patch fixes a segfault with Metal theme and -Dgnu.java.awt.peer.gtk.Graphics=Graphics2D on our swing demo.

The side effect is that the window bars in Dektop World look a bit ugly.

Ok?

Andreas

2005-09-29  Andreas Tobler  <address@hidden>

    * native/jni/gtk-peer/gnu_java_awt_peer_gtk_GdkGraphics2D.c
    (Java_gnu_java_awt_peer_gtk_GdkGraphics2D_setTexturePixelsUnlocked):
Call cairo_pattern_set_extend after gr->pattern has been set and checked
    versus NULL.


------------------------------------------------------------------------

Index: native/jni/gtk-peer/gnu_java_awt_peer_gtk_GdkGraphics2D.c
===================================================================
RCS file: 
/cvsroot/classpath/classpath/native/jni/gtk-peer/gnu_java_awt_peer_gtk_GdkGraphics2D.c,v
retrieving revision 1.32
diff -u -r1.32 gnu_java_awt_peer_gtk_GdkGraphics2D.c
--- native/jni/gtk-peer/gnu_java_awt_peer_gtk_GdkGraphics2D.c   18 Aug 2005 
01:22:00 -0000      1.32
+++ native/jni/gtk-peer/gnu_java_awt_peer_gtk_GdkGraphics2D.c   29 Sep 2005 
20:49:01 -0000
@@ -931,9 +931,9 @@
CAIRO_FORMAT_ARGB32, w, h, stride * 4);
   g_assert (gr->pattern_surface != NULL);
-  cairo_pattern_set_extend (gr->pattern, 1);
   gr->pattern = cairo_pattern_create_for_surface (gr->pattern_surface);
   g_assert (gr->pattern != NULL);
+  cairo_pattern_set_extend (gr->pattern, CAIRO_EXTEND_REPEAT);
   cairo_set_source (gr->cr, gr->pattern);
 }

------------------------------------------------------------------------

_______________________________________________
Classpath-patches mailing list
address@hidden
http://lists.gnu.org/mailman/listinfo/classpath-patches





reply via email to

[Prev in Thread] Current Thread [Next in Thread]