Skip to Content.
Sympa Menu

freetds - Re: tds_login and tds_config

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: Frediano Ziglio <freddyz77 AT tin.it>
  • To: TDS Development Group <freetds AT franklin.oit.unc.edu>
  • Subject: Re: tds_login and tds_config
  • Date: 15 Oct 2002 08:21:21 +0200


Il mar, 2002-10-15 alle 03:44, Brian Bruns ha scritto:
> Let me explain why things are the way they are currently, and I agree it's
> suboptimal.
>
> tds_login is called before a server name has been passed, and can reused
> across server connections (even to different servers). Since it is set by
> the application program, it takes precedence over config file/environment
> settings.
>
> tds_config is loaded once we know the server name, but applied first and
> overridden by tds_login. So, if you want to memcpy the tds_login (can't
> touch the original, it may be reused) and then apply the config file
> settings in an "if not set" manner, it should work correctly.
>
> Brian
>

Ok, then I think I'll do such things

Rename tds_config to tds_connect_info (tds_config do not store only
configuration information, so name seem not correct)
Declare tds_connect_info with first fields equal to tds_config (or use a
single field login_info)
Write a tds_login_copy function (I'd like to rewrite tds_login with
TDS_CHAR* fields instead of fixed buffers).

freddy77






Archive powered by MHonArc 2.6.24.

Top of Page