OAF CVS HEAD SEGV
- From: Ross Golder <ross golder org>
- To: gnome-components-list gnome org
- Subject: OAF CVS HEAD SEGV
- Date: 01 Oct 2001 16:07:18 +0100
With a RedHat 7.1 machine, Ximian updates, and CVS HEAD ORBit2 (etc),
oaf etc, I get :
[rossg durban rossg]$ gdb oafd
(gdb) run
Starting program: /usr/bin/oafd
Program received signal SIGSEGV, Segmentation fault.
od_utils_load_config_file () at od-utils.c:66
66 search_node = doc->xmlRootNode->xmlChildrenNode;
(gdb) bt
#0 od_utils_load_config_file () at od-utils.c:66
#1 0x080529d0 in main (argc=1, argv=0xbffff684) at main.c:168
#2 0x401a0177 in __libc_start_main (main=0x805280c <main>, argc=1,
ubp_av=0xbffff684, init=0x804befc <_init>, fini=0x80553a0 <_fini>,
rtld_fini=0x4000d3c4 <_dl_fini>, stack_end=0xbffff67c)
at ../sysdeps/generic/libc-start.c:129
I'm assuming that doc is being returned NULL from:
64 doc = od_utils_load_xml_file ();
So, I've patched it as follows to avoid SEGV.
Index: od-utils.c
===================================================================
RCS file: /cvs/gnome/oaf/oafd/od-utils.c,v
retrieving revision 1.10
diff -c -r1.10 od-utils.c
*** od-utils.c 2000/12/30 15:09:52 1.10
--- od-utils.c 2001/10/01 12:22:44
***************
*** 62,67 ****
--- 62,70 ----
xmlNodePtr search_node;
doc = od_utils_load_xml_file ();
+ if (doc == NULL) {
+ return NULL;
+ }
search_node = doc->xmlRootNode->xmlChildrenNode;
result = g_strdup ("");
Hope this helps,
--
Ross
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]