Skip to Content.
Sympa Menu

freetds - [freetds] INT_EXIT error returned for msgno 20009

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "J.A." <und3r53v3n AT gmail.com>
  • To: freetds AT lists.ibiblio.org
  • Subject: [freetds] INT_EXIT error returned for msgno 20009
  • Date: Mon, 31 Oct 2011 13:43:47 -0400

Hello,

I am getting the following error when I run my code:
FreeTDS: db-lib: exiting because client error handler returned INT_EXIT for
msgno 2 0009
I'm using Gnu C to attempt to connect to a MS Sqlserver 2008 instance. I
have a freetds.conf file that successfully connects using tsql. I checked
the log and it was not present. This leads me to believe the problem is my
code is not using the config file (which apparently works).

how do I make my code use the config file?

currently (what I think to be the important parts, looks like this:


#include <stdio.h>
#include <unistd.h>
#include <sys/param.h>
#include <sybfront.h>
#include <sybdb.h>
#include <syberror.h>

#define UID "user" \\ fake params for post
#define PWD "password"
//#define PROGNAME "sqllive"
#define DBSERVER "1.1.1.1"
#define DBNAME "Instace"


int main(void)
{
LOGINREC *login;
DBPROCESS *dbconn;
char hostname[MAXHOSTNAMELEN];
int max_len = MAXHOSTNAMELEN;
DBCHAR accession[10];
DBCHAR examdesc[10];
DBCHAR examcode[255];
/* Init the DB library */
if (dbinit() == FAIL) {
fprintf(stderr, "Could not init db.\n");
Since I'm not getting to the print part, I think it is safe to say the code
is failing prior to this line.

Please help




Archive powered by MHonArc 2.6.24.

Top of Page