--- textview.c	2004-03-07 05:54:20.000000000 +1100
+++ textview2.c	2004-04-25 23:24:20.000000000 +1000
@@ -556,6 +556,8 @@
   GtkTextChildAnchor *anchor;
   GtkWidget *sw;
 
+  gpointer pwindow;
+
   if (window)
     {
       gtk_window_present (GTK_WINDOW (window));
@@ -588,7 +590,9 @@
   gtk_container_add (GTK_CONTAINER (sw), view);
 
   g_object_add_weak_pointer (G_OBJECT (window),
-                             (gpointer *) &window);
+                             &pwindow);
+
+  window = (GtkWidget*) &pwindow;
 
   gtk_window_set_default_size (GTK_WINDOW (window), 300, 400);
   
