freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Frediano Ziglio <freddy77 AT gmail.com>
- To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
- Subject: Re: [freetds] [0.95rc2] Unit Tests / Unicode
- Date: Sat, 16 May 2015 06:12:18 +0100
2015-05-15 8:49 GMT+01:00 Sergio NNX <sfhacker AT hotmail.com>:
> CC long_error.o
> In file included from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> sql.h:19:0,
> from common.h:24,
> from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/sqltypes.h:87:29:
> erro
> r: conflicting types for 'TCHAR'
> In file included from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windef.h:239:0,
> from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windows.h:60,
> from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> winsock2.h:40,
> from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> ws2tcpip.h:41,
> from common.h:3,
> from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/winnt.h:136:15:
> note:
> previous declaration of 'TCHAR' was here
> In file included from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> sql.h:19:0,
> from common.h:24,
> from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/sqltypes.h:111:29:
> err
> or: conflicting types for 'LPTSTR'
> In file included from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windef.h:239:0,
> from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> windows.h:60,
> from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> winsock2.h:40,
> from
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/
> ws2tcpip.h:41,
> from common.h:3,
> from long_error.c:3:
> c:\mingw\bin\../lib/gcc/mingw32/4.7.2/../../../../include/winnt.h:154:30:
> note:
> previous declaration of 'LPTSTR' was here
> make[1]: *** [long_error.o] Error 1
>
Hi Sergio,
Can you try this version?
Can you post DUMPs for rpc tests ? Use a temporary user you you are
afraid of security leaks of send privately to me.
Thanks,
Frediano
PS: Are you Italian ? What's your real name ?
#include "common.h" /* Demonstration of triggered assert when invoking this stored procedure using FreeTDS odbc driver: create procedure proc_longerror as begin raiserror('reallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylongreallylong error', 16, 1) end */ static void extract_error(SQLHANDLE handle, SQLSMALLINT type); int main(void) { int i; char cmd[128 + 110*10]; printf("SQLWCHAR size is: %d\n", (int) sizeof(SQLWCHAR)); odbc_use_version3 = 1; odbc_connect(); /* this test do not work with Sybase */ if (!odbc_db_is_microsoft()) { odbc_disconnect(); return 0; } strcpy(cmd, "create procedure #proc_longerror as\nbegin\nraiserror('"); for (i = 0; i < 110; ++i) strcat(cmd, "reallylong"); strcat(cmd, " error', 16, 1)\nend\n"); odbc_command(cmd); CHKR2(SQLExecDirectW, (odbc_stmt, odbc_get_sqlwchar(&odbc_buf, "{CALL #proc_longerror}"), SQL_NTS), SQL_HANDLE_STMT, odbc_stmt, "E"); extract_error(odbc_stmt, SQL_HANDLE_STMT); odbc_disconnect(); return 0; } static void extract_error(SQLHANDLE handle, SQLSMALLINT type) { SQLINTEGER i = 0; SQLINTEGER native; SQLWCHAR state[7]; SQLWCHAR text[256]; SQLSMALLINT len; SQLRETURN ret; fprintf(stderr, "\n" "The driver reported the following diagnostics\n"); do { ret = SQLGetDiagRecW(type, handle, ++i, state, &native, text, 256, &len); state[5] = 0; if (SQL_SUCCEEDED(ret)) printf("%s:%ld:%ld:%s\n", odbc_get_sqlchar(&odbc_buf, state), (long) i, (long) native, odbc_get_sqlchar(&odbc_buf, text)); } while (ret == SQL_SUCCESS); }
-
Re: [freetds] [0.95rc2] Preliminary test results
, (continued)
- Re: [freetds] [0.95rc2] Preliminary test results, Frediano Ziglio, 05/12/2015
- [freetds] [0.95rc2][Windows] Deployment, Sergio NNX, 05/13/2015
- Re: [freetds] [0.95rc2][Windows] Deployment, Frediano Ziglio, 05/14/2015
- [freetds] [0.95rc2][Windows] Unit Tests, Sergio NNX, 05/14/2015
- Re: [freetds] [0.95rc2][Windows] Unit Tests, Frediano Ziglio, 05/14/2015
- Re: [freetds] [0.95rc2][Windows] Unit Tests, Sergio NNX, 05/14/2015
- Re: [freetds] [0.95rc2][Windows] Unit Tests, Frediano Ziglio, 05/14/2015
- [freetds] [0.95rc2][Windows] Unit Tests / Next release, Sergio NNX, 05/15/2015
- [freetds] [0.95rc2] Unit Tests / Unicode, Sergio NNX, 05/15/2015
- Re: [freetds] [0.95rc2] Unit Tests / Unicode, Frediano Ziglio, 05/15/2015
- Re: [freetds] [0.95rc2] Unit Tests / Unicode, Frediano Ziglio, 05/16/2015
Archive powered by MHonArc 2.6.24.