diff options
author | Bruce Momjian <bruce@momjian.us> | 2000-11-16 05:51:07 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2000-11-16 05:51:07 +0000 |
commit | 312063c97be346c3ce01faff021e9bff0464fa5c (patch) | |
tree | a4b33aa5242b3e1172379308804f3b06a89857bc /src/interfaces/libpq/fe-misc.c | |
parent | 580d2bc60f0e225e3fffc4da81039cf28e249749 (diff) | |
download | postgresql-312063c97be346c3ce01faff021e9bff0464fa5c.tar.gz postgresql-312063c97be346c3ce01faff021e9bff0464fa5c.zip |
Make pgsql compile on FreeBSD-alpha.
Context diff this time.
Remove -m486 compile args for FreeBSD-i386, compile -O2 on i386.
Compile with only -O on alpha for codegen safety.
Make the port use the TEST_AND_SET for alpha and i386 on FreeBSD.
Fix a lot of bogus string formats for outputting pointers (cast to int
and %u/%x replaced with no cast and %p), and 'Size'(size_t) are now
cast to 'unsigned long' and output with %lu/
Remove an unused variable.
Alfred Perlstein
Diffstat (limited to 'src/interfaces/libpq/fe-misc.c')
-rw-r--r-- | src/interfaces/libpq/fe-misc.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/interfaces/libpq/fe-misc.c b/src/interfaces/libpq/fe-misc.c index d7f1b6e1549..fff8ee6da97 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.41 2000/04/12 17:17:15 momjian Exp $ + * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-misc.c,v 1.42 2000/11/16 05:51:05 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -209,7 +209,7 @@ pqGetnchar(char *s, size_t len, PGconn *conn) conn->inCursor += len; if (conn->Pfdebug) - fprintf(conn->Pfdebug, "From backend (%d)> %.*s\n", len, (int) len, s); + fprintf(conn->Pfdebug, "From backend (%lu)> %.*s\n", (unsigned long)len, (int) len, s); return 0; } @@ -260,13 +260,13 @@ pqGetInt(int *result, size_t bytes, PGconn *conn) break; default: sprintf(noticeBuf, - "pqGetInt: int size %d not supported\n", bytes); + "pqGetInt: int size %lu not supported\n", (unsigned long)bytes); DONOTICE(conn, noticeBuf); return EOF; } if (conn->Pfdebug) - fprintf(conn->Pfdebug, "From backend (#%d)> %d\n", bytes, *result); + fprintf(conn->Pfdebug, "From backend (#%lu)> %d\n", (unsigned long)bytes, *result); return 0; } @@ -297,13 +297,13 @@ pqPutInt(int value, size_t bytes, PGconn *conn) break; default: sprintf(noticeBuf, - "pqPutInt: int size %d not supported\n", bytes); + "pqPutInt: int size %lu not supported\n", (unsigned long)bytes); DONOTICE(conn, noticeBuf); return EOF; } if (conn->Pfdebug) - fprintf(conn->Pfdebug, "To backend (%d#)> %d\n", bytes, value); + fprintf(conn->Pfdebug, "To backend (%lu#)> %d\n", (unsigned long)bytes, value); return 0; } |