A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.ncbi.nlm.nih.gov/IEB/ToolBox/CPP_DOC/doxyhtml/portconf_8c_source.html below:

NCBI C++ ToolKit: src/dbapi/driver/ftds14/freetds/tds/unittests/portconf.c Source File

Go to the documentation of this file.

Go to the SVN repository for this file.

20 #include <freetds/replacements.h> 29

FILE *

f

= fopen(in_file,

"r"

);

31

in_file =

"portconf.in"

;

32  f

= fopen(in_file,

"r"

);

35

fprintf(stderr,

"error opening test file\n"

);

45

printf(

"Dump login %s\n"

, name);

46 #define STR(name) printf(" "

#name ": %s\n", tds_dstr_cstr(&login->name));

47 #define INT(name) printf(" "

#name ": %d\n", login->name);

49  STR

(server_host_name);

62

fprintf(stderr,

"Error setting login!\n"

);

73

connection->

port

) < 0)

76

fprintf(stderr,

"Mismatch line %d:\n OUT: %s\n EXP: %s\n"

,

84 #define test(in, out) test0(ctx, tds, in, out, __LINE__) 94  f

= fopen(

"empty.conf"

,

"w"

);

97  putenv

(

"FREETDSCONF=empty.conf"

);

102

fprintf(stderr,

"Error creating socket!\n"

);

106  test

(

"NotExistingServer1:1234"

,

"my_server,8.7.6.5,,1234"

);

107  test

(

"localhost:1234"

,

"localhost,localhost,,1234"

);

108  test

(

"NotExistingServer1\\named"

,

"my_server,8.7.6.5,named,0"

);

109  test

(

"localhost\\named"

,

"localhost,localhost,named,0"

);

110  test

(

"2.3.4.5:2345"

,

"2.3.4.5,2.3.4.5,,2345"

);

111  test

(

"[2::3]:432"

,

"2::3,2::3,,432"

);

112  test

(

"[2::3:4]\\instance"

,

"2::3:4,2::3:4,instance,0"

);

static const char * expected[]

#define tds_read_config_info

#define tds_set_interfaces_file_loc

#define tds_alloc_context

static const char * tds_dstr_cstr(DSTR *s)

Returns a C version (NUL terminated string) of dstr.

int strcmp(const char *str1, const char *str2)

static void dump_login(const char *name, const TDSLOGIN *login)

static void set_interface(void)

static void test0(TDSCONTEXT *ctx, TDSSOCKET *tds, const char *input, const char *expected, int line)

DSTR server_name

server name (in freetds.conf)

int port

port of database service

Information for a server connection.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4