Skip to main content

Thread: C and GTK help...


hello friends,

making simple gtk program using codeblocks. here code:

code:
int main(int argc, char **argv) {     gladexml *xml;     gchar *filename;      gnomeprogram *program;      g_type_init();      filename = gnome_program_locate_file(program, gnome_file_domain_app_datadir, "ptms.glade", true, null);      xml = glade_xml_new(filename, "window1", null);      gtk_main();      return 0; }
this program showing following errors:

/package.projects/c/ptms/src/main.c|25|warning: variable ‘xml’ set not used [-wunused-but-set-variable]|
/package.projects/c/ptms/src/framework.h|21|warning: ‘pkginfo’ defined not used [-wunused-variable]|
/package.projects/c/ptms/src/main.c||in function ‘main’
/package.projects/c/ptms/src/main.c|32|warning: ‘program’ used uninitialized in function [-wuninitialized]|
||=== build finished: 0 errors, 3 warnings ===|

, if running program via terminal error :
segmentation fault

please help.

/package.projects/c/ptms/src/main.c|32|warning: ‘program’ used uninitialized in function [-wuninitialized]|
sign bad happen, need have program point sort of valid gnomeprogram or replace null use current application.


Forum The Ubuntu Forum Community Ubuntu Specialised Support Development & Programming Programming Talk C and GTK help...


Ubuntu

Comments

Popular posts from this blog

Falang and too many redirects - Joomla! Forum - community, help and support

Infinite loop detected in JErrorInfinite loop detected in JError - Joomla! Forum - community, help and support

logged out from joomla! - Joomla! Forum - community, help and support