Re: Segmentation Fault Question



I've managed to narrow the problem down a bit.  The segmentation fault
occurs when the function display() calls gtk_window_new.  Does anyone
have any ideas what gtk_window_new is doing to cause a segfault here?

Mel

Mel Harbour wrote:
Appologies if this isn't the right place to post this!

A program I'm writing, using GTK, is failing to run correctly. In short it throws out a segmentation fault the first time I call something gtk related other than gtk_init.

My code is at http://www.srcf.ucam.org/~mrh30/sandbox.c
with header file sandbox.h from the same address.

The fault originates somewhere in the function permittedsyscall. If I comment out the line 'display();' in the above function, the program runs as expected and will output a list of all the files opened by the program run through the sandbox.

If you get rid of the code to extract those filenames and put the display() line back in, it also runs (apparently) correctly, putting a window up on screen.

If I have both however, I get segmentation faults, which I would have thought was quite odd since neither part has any dealings with the other part.

Mel

_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list








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