Re: GtkEntry bug




Tony Gale <gale@daedalus.dera.gov.uk> writes:

> On 02-Mar-98 Bakstein Hynek wrote:
> >     I looked at gtk_entry.c and found that there is test: 
> > entry != NULL _BEFORE_ this variable is inicialized!
> 
> Yeah, I think that line should read:
> 
>    g_return_if_fail (editable != NULL);     
> 
> I was just looking into this myself.

Yes, it should. There are also a couple of other instances
of the same problem in gtkentry.c.

Regards,
                                        Owen

Index: gtkentry.c
===================================================================
RCS file: /debian/home/gnomecvs/gtk+/gtk/gtkentry.c,v
retrieving revision 1.23
diff -u -r1.23 gtkentry.c
--- gtkentry.c	1998/03/01 17:50:37	1.23
+++ gtkentry.c	1998/03/02 17:22:12
@@ -1395,7 +1395,7 @@
 
   GtkEntry *entry;
   
-  g_return_if_fail (entry != NULL);
+  g_return_if_fail (editable != NULL);
   g_return_if_fail (GTK_IS_ENTRY (editable));
 
   entry = GTK_ENTRY (editable);
@@ -1444,7 +1444,7 @@
 
   GtkEntry *entry;
   
-  g_return_if_fail (entry != NULL);
+  g_return_if_fail (editable != NULL);
   g_return_if_fail (GTK_IS_ENTRY (editable));
 
   entry = GTK_ENTRY (editable);
@@ -1494,7 +1494,7 @@
   GtkEntry *entry;
   gchar c;
   
-  g_return_val_if_fail (entry != NULL, NULL);
+  g_return_val_if_fail (editable != NULL, NULL);
   g_return_val_if_fail (GTK_IS_ENTRY (editable), NULL);
 
   entry = GTK_ENTRY (editable);



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