pg.ddx.io  pgsql-interfaces@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Small patch to compile clean against VC++ 5.0
2+ messages / 2 participants
[nested] [flat]

* Small patch to compile clean against VC++ 5.0
@ 1998-04-15 21:07 Julia A.Case <julie@hub.org>
  1998-04-16 22:33 ` Re: Small patch to compile clean against VC++ 5.0 Byron Nikolaidis <byronn@insightdist.com>
  0 siblings, 1 reply; 2+ messages in thread

From: Julia A.Case @ 1998-04-15 21:07 UTC (permalink / raw)
  To: Byron Nikolaidis <byronn@insightdist.com>; Julia A.Case <julie@postgreSQL.org>; pgsql-interfaces; Marc G. Fournier <scrappy@hub.org>; pgsql-questions@postgreSQL.org

inline patch 1: new/connection.c, new/environ.h, new/misc.h and 1 more (+4/-2 lines) download inline-1.patchdiff -uwd old/connection.c new/connection.c --- old/connection.c Wed Apr 15 16:42:00 1998 +++ new/connection.c Wed Apr 15 21:56:01 1998 @@ -1150,7 +1150,7 @@ return; } - result = SQLGetData(hstmt, 1, SQL_C_SLONG, &self->lobj_type, sizeof(self->lobj_type), NULL); + result = SQLGetData(hstmt, 1, SQL_C_LONG, &self->lobj_type, sizeof(self->lobj_type), NULL); if((result != SQL_SUCCESS) && (result != SQL_SUCCESS_WITH_INFO)) { SQLFreeStmt(hstmt, SQL_DROP); return; diff -uwd old/environ.h new/environ.h --- old/environ.h Fri Mar 27 11:06:06 1998 +++ new/environ.h Wed Apr 15 21:56:02 1998 @@ -13,6 +13,7 @@ #include "psqlodbc.h" #include <windows.h> #include <sql.h> +#include <sqlext.h> #define ENV_ALLOC_ERROR 1 diff -uwd old/misc.h new/misc.h --- old/misc.h Wed Apr 15 12:29:22 1998 +++ new/misc.h Wed Apr 15 22:00:26 1998 @@ -26,7 +26,7 @@ 'CommLog' flag in the ODBCINST.INI portion of the registry (see above), which is manipulated on the setup/connection dialog boxes. */ -#define Q_LOG +// #define Q_LOG #ifdef MY_LOG diff -uwd old/options.c new/options.c --- old/options.c Tue Mar 24 13:36:30 1998 +++ new/options.c Wed Apr 15 21:56:02 1998 @@ -16,6 +16,7 @@ #include "psqlodbc.h" #include <windows.h> #include <sql.h> +#include <sqlext.h> #include "environ.h" #include "connection.h" #include "statement.h"
-- [ Julia Anne Case ] [ Ships are safe inside the harbor, ] [Programmer at large] [ but is that what ships are really for. ] [ Admining Linux ] [ To thine own self be true. ] [ Windows/WindowsNT ] [ Fair is where you take your cows to be judged. ] ^ permalink raw reply [nested|flat] 2+ messages in thread

* Re: Small patch to compile clean against VC++ 5.0
  1998-04-15 21:07 Small patch to compile clean against VC++ 5.0 Julia A.Case <julie@hub.org>
@ 1998-04-16 22:33 ` Byron Nikolaidis <byronn@insightdist.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Byron Nikolaidis @ 1998-04-16 22:33 UTC (permalink / raw)
  To: Julia A.Case <julie@MageNet.com>; pgsql-interfaces

Julia,

I made all the patches to let it compile clean on MS VC 5.0
I reworked some things with the order of the wonderful Microsoft header files so that the Q_LOG can remain
compiled in yet the driver compiles clean.

I'll put the latest stuff on the web site still until I hear otherwise.

Regards,

Byron



Julia A.Case wrote:

> Quoting Byron Nikolaidis (byronn@insightdist.com):
> > Julia,
> >
> > I would like to make it compile on 5.0 also, I just have a couple of questions about this patch:
> >
> > > -       result = SQLGetData(hstmt, 1, SQL_C_SLONG, &self->lobj_type, sizeof(self->lobj_type), NULL);
> > > +       result = SQLGetData(hstmt, 1, SQL_C_LONG, &self->lobj_type, sizeof(self->lobj_type), NULL);
> >
> > SQL_C_SLONG is the ODBC 2.0 type to use and should be in sql.h; SQL_C_LONG is a ODBC 1.0 type.
> >
>         Perhaps there was another missing <sqlext.h>  ???
>
> > > -#define Q_LOG
> > > +// #define Q_LOG
> > >
> > >
> >
> > Why would this cause a problem?  This is to compile in the communications log feature which is quite
> > useful and was wanted for a long time.  If it is commented out like you have shown it, it could not be
> > activated from the setup dialog boxes.
> >
> > Do these things cause warnings or errors?
> >
>         the va_args macros cause errors...  and to be honest I don't know
> enough to fix them, so it seemed simpler to comment them out.  Will that
> many END users be using Q_LOG?  I'd think that would mostly be a developer
> thing...  and if so, a developer could uncomment it if they wanted it.
>
> Julie
>
> --
> [  Julia Anne Case  ] [        Ships are safe inside the harbor,       ]
> [Programmer at large] [      but is that what ships are really for.    ]
> [   Admining Linux  ] [           To thine own self be true.           ]
> [ Windows/WindowsNT ] [ Fair is where you take your cows to be judged. ]






^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~1998-04-16 22:33 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
1998-04-15 21:07 Small patch to compile clean against VC++ 5.0 Julia A.Case <julie@hub.org>
1998-04-16 22:33 ` Byron Nikolaidis <byronn@insightdist.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox