Skip to Content.
Sympa Menu

freetds - Re: [freetds] dblastrow?

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "James K. Lowden" <jklowden AT schemamania.org>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: Re: [freetds] dblastrow?
  • Date: Wed, 21 Jul 2004 20:57:58 -0400

On Wed, 21 Jul 2004, Geoff Wong <geoff AT shattered.org> wrote:
>
> dblastrow() crashes in the following code:
>
...
> if (dbrpcsend(dbProc) == FAIL)
...
> if (dbsqlok(dbProc) == FAIL)
...
> if (dbresults(dbProc) == FAIL)
...
>
> 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;

I think it must depend on the SQL (or something). That calling sequence
is completely standard and should always work. src/dblib/unittests/rpc.c
does exactly that (and works). Perhaps your query returns no rows? Not
that that should be a problem....

If you could send post a complete [non]working program that exposes this
bug, perhaps a modified unit test, I'd be happy to look into it further.
Other suggestions welcome, too. ;-)

--jkl




Archive powered by MHonArc 2.6.24.

Top of Page