freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Geoff Wong <geoff AT shattered.org>
- To: freetds AT lists.ibiblio.org
- Subject: [freetds] dblastrow?
- Date: Wed, 21 Jul 2004 17:31:09 +1000
dblastrow() crashes in the following code:
--------
BOOL SQLSVRDB_OpenProcCursor(DBPROCESS *dbProc)
{
LOG_PROC_MSG( "SQLSVRDB_OpenProcCursor(): dbProc=" << dbProc ) ;
if (dbrpcsend(dbProc) == FAIL)
{
LOG_PROC_MSG( "ERROR: dbrpcsend() failed." ) ;
return FALSE;
}
if (dbsqlok(dbProc) == FAIL)
{
LOG_PROC_MSG( "ERROR: dbsqlok() failed." ) ;
return FALSE;
}
if (dbresults(dbProc) == FAIL)
{
LOG_PROC_MSG( "dbresults() failed." ) ;
return FALSE;
}
#if 1
printf("OpenProcCursor (rows=%d,cols=%d)\n", dblastrow(dbProc),
dbnumcols(dbProc));
#endif
return TRUE;
}
--------
It crashes here:
DBINT
dblastrow(DBPROCESS * dbproc)
{
TDSRESULTINFO *resinfo;
TDSSOCKET *tds;
tds = (TDSSOCKET *) dbproc->tds_socket;
line 5872 **** resinfo = tds->res_info;
return resinfo->row_count;
Should it work?
Or am I doing something wrong?
Even if I'm doing something wrong .. I don't think it should crash here.
Geoff
-
[freetds] dblastrow?,
Geoff Wong, 07/21/2004
- Re: [freetds] dblastrow?, Geoff Wong, 07/21/2004
- Re: [freetds] dblastrow?, James K. Lowden, 07/21/2004
Archive powered by MHonArc 2.6.24.