mirror of
https://github.com/postgres/postgres.git
synced 2025-10-31 10:30:33 +03:00
Attached is a patch to remove the definitions of libpq's internal
structs from libpq-fe.h, as we previously discussed. There turned out to be sloppy coding practices in more places than I had realized :-(, but all in all I think it was a well-worth-while exercise. I ended up adding several routines to libpq's API in order to respond to application requirements that were exposed by this work. I owe the docs crew updates for libpq.sgml to describe these changes. I'm way too tired to work on the docs tonight, however. This is the last major change I intend to submit for 6.4. I do want to see if I can make libpgtcl work with Tcl 8.0 before we go final, but hopefully that will be a minor bug fix.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
/*-------------------------------------------------------
|
||||
*
|
||||
* $Id: Pg.xs,v 1.7 1998/06/01 16:41:19 mergl Exp $
|
||||
* $Id: Pg.xs,v 1.8 1998/09/03 02:10:56 momjian Exp $
|
||||
*
|
||||
* Copyright (c) 1997, 1998 Edmund Mergl
|
||||
*
|
||||
@@ -318,7 +318,7 @@ PQexec(conn, query)
|
||||
char * query
|
||||
CODE:
|
||||
RETVAL = PQexec(conn, query);
|
||||
if (! RETVAL) { RETVAL = (PGresult *)calloc(1, sizeof(PGresult)); }
|
||||
if (! RETVAL) { RETVAL = PQmakeEmptyPGresult(conn, PGRES_FATAL_ERROR); }
|
||||
OUTPUT:
|
||||
RETVAL
|
||||
|
||||
@@ -752,7 +752,7 @@ PQexec(conn, query)
|
||||
if (RETVAL) {
|
||||
RETVAL->result = PQexec((PGconn *)conn, query);
|
||||
if (!RETVAL->result) {
|
||||
RETVAL->result = (PG_result)calloc(1, sizeof(PGresult));
|
||||
RETVAL->result = PQmakeEmptyPGresult(conn, PGRES_FATAL_ERROR);
|
||||
}
|
||||
}
|
||||
OUTPUT:
|
||||
|
||||
Reference in New Issue
Block a user