Passing Struct through g_signal_connect. Segmentation Fault on exit.
- From: Vasili Sviridov <vsviridov exceede com>
- To: gtk-devel-list gnome org
- Subject: Passing Struct through g_signal_connect. Segmentation Fault on exit.
- Date: Wed, 06 Apr 2005 20:44:26 -0700
This is my first attempt to write something with GTK+ and LibGlade.
When I pass a struct with my data to the function using
g_signal_connect, even if i'm not doing anything with that data in the
function itself (like f(){};) when I close the application I get
Segmentation Fault Error.
typedef struct myStruct
{
GtkWidget * Widget;
gint i;
}myStruct;
struct myStruct *p;
p->Widget = {some widget};
p->i = {some number};
g_signal_connect(G_OBJECT(BtnConnect),"clicked",G_CALLBACK(f),(gpointer)p);
How would I fix that?
Regards,
Vasili Sviridov.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]