Re: hate to bother again, gtk2 is causing errors that gtk1 didn't



Hi,

Brandon McCombs <brandon ovnet com> writes:

> I'm still working on my lottery program. GTK2 doesn't seem to like
> something that GTK1 had no problem with.
> This code only works in GTK1.2.8 and is causing the errors below, along
> with a segfault.
>  for (i=0; i<3; i++)
>    {
>     pick3comp[i] = rand()%10;
>     tmp = gtk_editable_get_chars(GTK_EDITABLE(pick3entry[i]), 0, -1);
>     pick3player[i] = atoi(tmp);
>     g_free(tmp);
>    }
> 
> GLib: Cannot convert message: Conversion from character set 'UTF-8' to
> 'POSIX' is not supported

looks like you are using a strange locale 'POSIX' which is not
supported by your version of iconv.

> (lottoextrasmesg2:31809): GLib-GObject-WARNING **: invalid cast from
> (NULL) pointer to `GtkEditable'
> 
> (lottoextrasmesg2:31809): Gtk-CRITICAL **: file gtkeditable.c: line 125
> (gtk_editable_get_chars): assertion `GTK_IS_EDITABLE (editable)' failed

the error message says it all, you are trying to use a NULL pointer as
a GtkEditable. Most probably something went wrong earlier when you
created it or you are having a bad memory corruption somewhere. Looks
like a job for gdb and probably valgrind.


Salut, Sven




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