Re: Class::DBI::Sybase segfaulting

Michael Peppler <[email protected]>
Newsgroups gmane.comp.lang.perl.modules.dbi.sybase
Message-ID <[email protected]>
On Mon, 2005-02-28 at 18:44, Ivor Williams wrote:
> Cross posted from Class::DBI list:
> 
> Here is a fairly trivial DB and script. What am I doing wrong?
> 
> OS is Solaris 5.8 and Sybase version 12.5.1
> 
> Class::DBI version 0.96
> DBI version 1.47
> DBD::Sybase version 0.95

Start by upgrading DBD::Sybase to 1.05.

Michael

> 
> From: Perrin Harkins <[email protected]> 
> To: [email protected] 
> Cc: "[email protected]" <[email protected]> 
> Subject: Re: Class::DBI segfaulting 
> Date: Mon, 28 Feb 2005 10:40:37 -0500 
> References: <[email protected]> 
> 
> > On Mon, 2005-02-28 at 14:47 +0000, [email protected] wrote:
> >> It's blowing up somewhere under set_up_table.
> >> There also doesn't seem to be anything special that Class:DBI::Sybase is 
> >> doing.
> >
> > Well, Class::DBI is pure perl, so either Perl is segfaulting, or
> > Class::DBI::Sybase (or some other XS module used in there) is doing it.
> > I'd suggest tracing it to the offending line in the debugger as a
> > starting point.
> 
> I've traced it to Class::DBI::Sybase line 86, where it is trying to
> retrieve the results from the procedure sp_help $table. It's actually
> segfaulting in Carp::Heavy, probably on account of some dodgy SV that
> DBD::Sybase has returned.
> 
> Any idea how I would go about tracking this down further?
> 
> 
>   DB<1> b 86
>   DB<2> c
> Class::DBI::Sybase::set_up_table(/home/williami/lib/Class/DBI/Sybase.pm:86):
> 86:             $col = $sth->fetchall_arrayref(); 
>   DB<2> T
> . = Class::DBI::Sybase::set_up_table('Test::DBI', 'TEST') called from file `cdbi_test.pl' line 11
>   DB<2> s
> DBI::st::fetchall_arrayref(/usr/local/lib/perl5/5.6.1/Carp.pm:97):
> 97:         { local $@; require Carp::Heavy; }  # XXX fix require to not clear $@?
>   DB<2> 
> DBI::st::fetchall_arrayref(/usr/local/lib/perl5/5.6.1/Carp.pm:97):
> 97:         { local $@; require Carp::Heavy; }  # XXX fix require to not clear $@?
>   DB<2> 
> DBI::st::fetchall_arrayref(/usr/local/lib/perl5/5.6.1/Carp.pm:97):
> 97:         { local $@; require Carp::Heavy; }  # XXX fix require to not clear $@?
>   DB<2> 
> DBI::st::fetchall_arrayref(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:247):
> 247:    1;
>   DB<2> 
> DBI::st::fetchall_arrayref(/usr/local/lib/perl5/5.6.1/Carp.pm:98):
> 98:         goto &longmess_heavy;
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:30):
> 30:         return @_ if ref $_[0];
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:31):
> 31:         my $error = join '', @_;
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:32):
> 32:         my $mess = "";
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:33):
> 33:         my $i = 1 + $CarpLevel;
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:34):
> 34:         my ($pack,$file,$line,$sub,$hargs,$eval,$require);
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:35):
> 35:         my (@a);
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:39):
> 39:         while (do { { package DB; @a = caller($i++) } } ) {
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:39):
> 39:         while (do { { package DB; @a = caller($i++) } } ) {
>   DB<2> 
> Carp::longmess_heavy(/usr/local/lib/perl5/5.6.1/Carp/Heavy.pm:124):
> 124:        $mess || $error;
>   DB<2> 
> Signal SEGV: 
> Abort(coredump)
> ==============================
> 
> Any thoughts?
-- 
Michael Peppler  -  [email protected]  -  http://www.peppler.org/
Sybase DBA/Developer
Sybase on Linux FAQ: http://www.peppler.org/FAQ/linux.html
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.