freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Michael Peppler <mpeppler AT peppler.org>
- To: "TDS Development Group" <freetds AT franklin.oit.unc.edu>
- Subject: Re: DBD::Sybase main.t crash
- Date: Thu, 26 Aug 1999 10:38:23 -0700 (PDT)
OK - now on Solaris 7, Sparc...
I've made sure that HW_BIG_ENDIAN is defined.
However, I get:
kiruna (10:33AM):123 > perl -Mblib t/main.t
Using /u6/home/mpeppler/src/Sybase-dist/DBD-Sybase-0.19/blib
1..12
ok 1
Switch: DBI-1.08 Switch by Tim Bunce, 1.08
Available Drivers: ADO, ExampleP, Proxy, Sybase
Unknown property 7
ok 2
ok 3
ct_describe() failed at t/main.t line 61.
3805:
Server message number=3805 severity=18 state=1 line=1 text=The token
datastream length was not correct. This is an internal protocol error.
not ok 4
not ok 5
zsh: segmentation fault (core dumped) perl -Mblib t/main.t
I'll try to run the whole thing in the debugger, but there seems to be
several problems here...
I may spend some more time on this, but you may be interested in
seeing this :-)
Michael
Michael Peppler writes:
> Michael Peppler writes:
> > Anyway - on linux I still core dump on the ct_connect(). The stack
> > trace gives me:
> >
> > (gdb) bt
> > #0 strncpy (s1=0x8192929 "", s2=0x0, n=30) at
> ../sysdeps/generic/strncpy.c:37
> > #1 0x2abd9a21 in tds_set_server (tds_login=0x81928b0, server=0x0)
> > at login.c:68
> > #2 0x2abd5e27 in ct_connect (con=0x8127378, servername=0x81aabf8 "",
> > snamelen=0) at ct.c:167
> > #3 0x2abcbf1a in syb_db_connect ()
> > #4 0x2abcb75f in syb_db_login ()
> > #5 0x2abc89a9 in XS_DBD__Sybase__db__login ()
> > #6 0x8087b7e in Perl_pp_entersub ()
> > #7 0x80b162e in Perl_runops_standard ()
> > #8 0x8058e01 in perl_call_sv ()
> > #9 0x2abbea3c in XS_DBI_dispatch ()
> > #10 0x8087b7e in Perl_pp_entersub ()
> > #11 0x80b162e in Perl_runops_standard ()
> > #12 0x8058791 in perl_run ()
> > #13 0x8056bdb in main ()
> >
> > So there seems to be an invalid strcpy going on here - note that I'm
> > not setting the server to anything, and expect the library to use the
> > contents of $DSQUERY or, if that is empty, 'SYBASE'.
> >
> > I'll make a patch in a minute.
>
> OK - here's a patch:
>
> troll (10:08AM):378 > diff -c login.c.old login.c
> *** login.c.old Thu Aug 26 10:08:12 1999
> --- login.c Thu Aug 26 10:07:10 1999
> ***************
> *** 65,70 ****
> --- 65,76 ----
> }
> void tds_set_server(TDSLOGIN *tds_login, char *server)
> {
> + if(!server || strlen(server) == 0) {
> + server = getenv("DSQUERY");
> + if(!server || strlen(server) == 0) {
> + server = "SYBASE";
> + }
> + }
> strncpy(tds_login->server_name, server,
> sizeof(tds_login->server_name));
> }
> void tds_set_library(TDSLOGIN *tds_login, char *library)
>
> This now runs on linux, apart from the "unknown property 7" message,
> and of course that ?-style placeholders are not supported yet (aka
> dynamic SQL.)
>
> Michael
> --
> Michael Peppler -||- Data Migrations Inc.
> mpeppler AT peppler.org -||- http://www.mbay.net/~mpeppler
> Int. Sybase User Group -||- http://www.isug.com
> Sybase on Linux mailing list: ase-linux-list AT isug.com
>
> ---
> You are currently subscribed to freetds as: mpeppler AT peppler.org
> To unsubscribe, forward this message to $subst('Email.Unsub')
>
--
Michael Peppler -||- Data Migrations Inc.
mpeppler AT peppler.org -||- http://www.mbay.net/~mpeppler
Int. Sybase User Group -||- http://www.isug.com
Sybase on Linux mailing list: ase-linux-list AT isug.com
-
Re: DBD::Sybase main.t crash,
Brian Bruns, 08/25/1999
- <Possible follow-up(s)>
- Re: DBD::Sybase main.t crash, Mark Schaal, 08/25/1999
- Re: DBD::Sybase main.t crash, Michael Peppler, 08/25/1999
- Re: DBD::Sybase main.t crash, Mark Schaal, 08/25/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/25/1999
- Re: DBD::Sybase main.t crash, Michael Peppler, 08/26/1999
- Re: DBD::Sybase main.t crash, Mark Schaal, 08/26/1999
- Re: DBD::Sybase main.t crash, Michael Peppler, 08/26/1999
- Re: DBD::Sybase main.t crash, Michael Peppler, 08/26/1999
- Re: DBD::Sybase main.t crash, Michael Peppler, 08/26/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/26/1999
- Re: DBD::Sybase main.t crash, Mark Schaal, 08/27/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/28/1999
- Re: DBD::Sybase main.t crash, Bill Tutt, 08/28/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/28/1999
- Re: DBD::Sybase main.t crash, Bill Tutt, 08/29/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/29/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/29/1999
- Re: DBD::Sybase main.t crash, Brian Bruns, 08/30/1999
- Re: DBD::Sybase main.t crash, Mark Schaal, 08/30/1999
Archive powered by MHonArc 2.6.24.