diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2002-06-15 22:06:09 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2002-06-15 22:06:09 +0000 |
commit | 32fecad80a88cff01903d9cce820e26acaf1fd42 (patch) | |
tree | 417e1a1125e39525e1dc16d4d0d4cf19c40614e8 /src/interfaces/libpq/fe-misc.c | |
parent | c63bc32c2cfecc5ac015594c36bd557ea48777a6 (diff) |
Clean up gcc warnings. Avoid the bad habit of putting externs in .c
files rather than a header file where they belong. Pay some modicum
of attention to picking global routine names that aren't likely to
conflict with surrounding applications.
Diffstat (limited to 'src/interfaces/libpq/fe-misc.c')
-rw-r--r-- | src/interfaces/libpq/fe-misc.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/src/interfaces/libpq/fe-misc.c b/src/interfaces/libpq/fe-misc.c index 94b641621a3..46231a21dfe 100644 --- a/src/interfaces/libpq/fe-misc.c +++ b/src/interfaces/libpq/fe-misc.c @@ -25,7 +25,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-misc.c,v 1.74 2002/06/15 20:01:31 momjian Exp $ + * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-misc.c,v 1.75 2002/06/15 22:06:09 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -55,10 +55,6 @@ #include "mb/pg_wchar.h" #endif -extern void secure_close(PGconn *); -extern ssize_t secure_read(PGconn *, void *, size_t); -extern ssize_t secure_write(PGconn *, const void *, size_t); - #define DONOTICE(conn,message) \ ((*(conn)->noticeHook) ((conn)->noticeArg, (message))) @@ -490,8 +486,8 @@ pqReadData(PGconn *conn) /* OK, try to read some data */ retry3: - nread = secure_read(conn, conn->inBuffer + conn->inEnd, - conn->inBufSize - conn->inEnd); + nread = pqsecure_read(conn, conn->inBuffer + conn->inEnd, + conn->inBufSize - conn->inEnd); if (nread < 0) { if (SOCK_ERRNO == EINTR) @@ -570,8 +566,8 @@ retry3: * arrived. */ retry4: - nread = secure_read(conn, conn->inBuffer + conn->inEnd, - conn->inBufSize - conn->inEnd); + nread = pqsecure_read(conn, conn->inBuffer + conn->inEnd, + conn->inBufSize - conn->inEnd); if (nread < 0) { if (SOCK_ERRNO == EINTR) @@ -612,7 +608,7 @@ definitelyFailed: "\tThis probably means the server terminated abnormally\n" "\tbefore or while processing the request.\n")); conn->status = CONNECTION_BAD; /* No more connection to backend */ - secure_close(conn); + pqsecure_close(conn); #ifdef WIN32 closesocket(conn->sock); #else @@ -654,7 +650,7 @@ pqSendSome(PGconn *conn) { int sent; - sent = secure_write(conn, ptr, len); + sent = pqsecure_write(conn, ptr, len); if (sent < 0) { |