Skip site navigation (1) Skip section navigation (2)

Re: C set return function differences on 8.0?

From: Tim Jackson <tim(dot)jackson(at)ints(dot)com>
To: Michael Fuhr <mike(at)fuhr(dot)org>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: C set return function differences on 8.0?
Date: 2005-07-11 23:09:28
Message-ID: 42D2FC28.8070908@ints.com (view raw or flat)
Thread:
Lists: pgsql-interfaces
Michael Fuhr wrote:

>
>Let's see if attaching a debugger to the backend or adding some
>ereport() calls can at least tell us where the crash is happening.
>Then maybe we can figure out why.
>  
>
I was able to set gdb to the pid of  psql  session and saw that selects 
on the "bad" views segfaulted on pfree()
The documentation for SRF had a comment that said pfree() was not really 
necessary so I commented that code out and now I can select all the 
views. :) 
Perhaps you can advise me on why pfree() would segfault on 8.0 in but 
not 7.4

Anyway the .so generated views are working now as they were on 7.4.
Thanks for your help. Tim


Not sure what all this means but the following lines were gleaned from 
the core dump

cannot allocate memory for thread-local data: ABORT
result == _rtld_local._dl_tls_max_dtv_idx + 1
result <= _rtld_local._dl_tls_max_dtv_idx + 1
@cnt < _rtld_local._dl_tls_dtv_slotinfo_list->len
_rtld_local._dl_tls_dtv_slotinfo_list->next == ((void *)0)
_rtld_local._dl_tls_dtv_slotinfo_list != ((void *)0)
_rtld_local._dl_tls_max_dtv_idx == 0
_rtld_local._dl_tls_dtv_slotinfo_list == ((void *)0)

(size_t) map->l_tls_offset >= map->l_tls_blocksize

map->l_tls_blocksize >= map->l_tls_initimage_size

../sysdeps/unix/sysv/linux/dl-origin.c

FATAL: cannot determine library version

../sysdeps/generic/dl-sysdep.c

Inconsistency detected by ld.so: %s: %u: %s%sAssertion `%s' failed!

Inconsistency detected by ld.so: %s: %u: %s%sUnexpected error: %s.

And Here is what gdb says about the core

Core was generated by `postgres: postgres lubesoft_tj [local] 
SELECT                     '.
Program terminated with signal 11, Segmentation fault.
#0  0x08222a86 in ?? ()
(no debugging symbols found)...Using host libthread_db library 
"/lib/tls/libthread_db.so.1".




In response to

pgsql-interfaces by date

Next:From: Tom LaneDate: 2005-07-12 14:31:22
Subject: Re: C set return function differences on 8.0?]]
Previous:From: Tim JacksonDate: 2005-07-11 21:37:07
Subject: Re: C set return function differences on 8.0?]]

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group