Re: pg_conn not declared in libpq-fe.h? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: pg_conn not declared in libpq-fe.h?
Date
Msg-id 13216.1058973249@sss.pgh.pa.us
Whole thread Raw
In response to Re: pg_conn not declared in libpq-fe.h?  (Hauke Joachim Zuehl <hzuehl@athene.dnsalias.org>)
List pgsql-hackers
Hauke Joachim Zuehl <hzuehl@athene.dnsalias.org> writes:
> Well, that's clear but there is another problem:
> hauke@fafnir [pgsql] >>grep -H "typedef.*PGconn" *.h
> libpq-fe.h:typedef struct pg_conn PGconn;
> hauke@fafnir [pgsql] >>grep -H "pg_conn" *.h
> libpq-fe.h:typedef struct pg_conn PGconn;
> hauke@fafnir [pgsql] >>

> So I miss the structure pg_conn :(
> Maybe I have to include more than just libpq-fe.h?

You're right, the contents of the structure are not exported by the
library.  Your code should only use pointers to the struct, so it ought
not care what is in the struct.
        regards, tom lane


pgsql-hackers by date:

Previous
From: The Hermit Hacker
Date:
Subject: Re: cvs problem
Next
From: Bruce Momjian
Date:
Subject: Re: php with postgres