[Openais] Re: openais segfault

Steven Dake sdake at redhat.com
Wed Apr 5 13:59:08 PDT 2006


the interface count is wrong and the instance data is wrong.  Mail me a
tarball of your binaries and source tree.

Try this attached patch and send the printf output.  It will tell us if
something is going wrong along the way.

run gcc -version maybe its a toolchain issue.  What arch are you on?

Have you tried valgrinding the code?  I can't imagine it could be a
memory overwrite, because the object database is loaded so early, but it
is possible.

Regards
-steve

On Wed, 2006-04-05 at 13:19 -0700, Mark Haverkamp wrote:
> On Wed, 2006-04-05 at 12:11 -0700, Steven Dake wrote:
> > Take out the static inline and give me a backtrace (line 74).  The
> > inline isn't showing the true backtrace that I'm interested to see.
> 
> OK, I removed all the static and inline from lcr_ifact.c functions. My
> file has:  
> 	unsigned int len;
> in function lcr_select_so() at line 74.
> 
> 
> (gdb) r
> Starting program: /home/localmarkh/views/svn/openais_work/exec/aisexec
> [Thread debugging using libthread_db enabled]
> [New Thread -151132480 (LWP 24047)]
> 
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread -151132480 (LWP 24047)]
> 0x08065cf7 in lcr_ifact_reference (iface_handle=0xfee32ca0,
>     iface_name=0x80685f6 "objdb", version=0, iface=0xfee32c9c, context=0x0)
>     at lcr_ifact.c:102
> 102                     for (i = 0; i < instance->iface_count; i++) {
> 
> 
> (gdb) bt
> #0  0x08065cf7 in lcr_ifact_reference (iface_handle=0xfee32ca0,
>     iface_name=0x80685f6 "objdb", version=0, iface=0xfee32c9c, context=0x0)
>     at lcr_ifact.c:102
> #1  0x0805fd6a in main () at main.c:1179
> (gdb)
> 
> (gdb) p lcr_component_instance_database
> $1 = {handle_count = 1, handles = 0x8d784c0, iterator = 1}
> (gdb) p instance
> $3 = (struct lcr_component_instance *) 0x7e5d55
> (gdb) p *instance
> $4 = {ifaces = 0x6d675f5f, iface_count = 1935634031, dl_handle =
> 0x74726174,
>   refcount = 1593859935,
>   library_name = "_cxa_finalize\000_Jv_RegisterClasses
> \000_nss_files_parse_protoent\000__ctype_b_loc\000__strtoul_internal
> \000__rawmemchr\000fopen\000__errno_location\000rewind\000fileno
> \000fcntl\000fclose\000_nss_files_setprotoent\000__pthread_mutex_lock
> \000_"...}
> 
> 
> > 
> > Thanks
> > -steve
> 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: debug-patch-for-mark.patch
Type: text/x-patch
Size: 1753 bytes
Desc: not available
Url : http://lists.linux-foundation.org/pipermail/openais/attachments/20060405/2a409918/debug-patch-for-mark-0001.bin


More information about the Openais mailing list