Skip to Content.
Sympa Menu

freetds - RE: shared object version numbers

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: ZIGLIO Frediano <Frediano.Ziglio AT vodafoneomnitel.it>
  • To: "'TDS Development Group'" <freetds AT franklin.metalab.unc.edu>
  • Subject: RE: shared object version numbers
  • Date: Tue, 24 Sep 2002 16:37:55 +0200


>
> The function was removed because it was getting in my way :-)
>

What's your second name? Attila? :)

> Seriously, it doesn't serve any useful purpose, and it was
> stomping on data
> that I needed. In src/tds/token.c:tds_process_msg(), notice that
> tds->msg_info->msg_number is accessed after the msg_handler
> has already been
> called. If our calling conventions require that the
> msg_handler zero this
> information, msg_number would always be gone by that point.
>
> It seemed silly to require that the calling function do this
> cleanup, when
> the caller will eventually call tds_free_msg(tds->msg_info)
> which (with a
> little tweaking) now does everything that
> tds_reset_msg_info() did before.
>

Agree. Altough I don't like a "free" function that do not free the given
pointer...
If we don't require a "free" I rather call it "reset"...

> I don't see any place in the code that requires a distinction
> between the
> functionality of tds_reset_msg_info() and tds_free_msg().
> Why retain an
> awkward and unnecessary interface?
>
> I don't know why there's a msg_info field in TDSSOCKET, so I
> just left that
> part alone.
>
> Cheers,

I think this structure is here for 2 reason:
- library can retrieve error bye watching in this structure. Only odbc use
this method but recently changes do not require this
- in token.c we checked for level after calling tds_process_msg. Changed to
see return code of tds_process_msg...

So I don't see any more reason for this field...

freddy77

=================================
"STRICTLY PERSONAL AND CONFIDENTIAL

This message may contain confidential and proprietary material for the sole
use of the intended recipient. Any review or distribution by others is
strictly prohibited. If you are not the intended recipient please contact
the sender and delete all copies.
The contents of this message that do not relate to the official business of
our company shall be understood as neither given nor endorsed by it."

=================================




Archive powered by MHonArc 2.6.24.

Top of Page