summaryrefslogtreecommitdiff
path: root/src/interfaces
diff options
context:
space:
mode:
authorBruce Momjian2011-06-09 18:32:50 +0000
committerBruce Momjian2011-06-09 18:32:50 +0000
commit6560407c7db2c7e32926a46f5fb52175ac10d9e5 (patch)
tree9641e538893819410634624a8e0cb86a13d857a6 /src/interfaces
parentadf43b2b36ca3d7f988933990051c74a4bd0d6f8 (diff)
Pgindent run before 9.1 beta2.
Diffstat (limited to 'src/interfaces')
-rw-r--r--src/interfaces/ecpg/ecpglib/sqlda.c8
-rw-r--r--src/interfaces/ecpg/pgtypeslib/timestamp.c4
-rw-r--r--src/interfaces/libpq/fe-auth.c8
-rw-r--r--src/interfaces/libpq/fe-connect.c22
4 files changed, 25 insertions, 17 deletions
diff --git a/src/interfaces/ecpg/ecpglib/sqlda.c b/src/interfaces/ecpg/ecpglib/sqlda.c
index c08c61b5df1..33b4d2bce3d 100644
--- a/src/interfaces/ecpg/ecpglib/sqlda.c
+++ b/src/interfaces/ecpg/ecpglib/sqlda.c
@@ -228,8 +228,12 @@ ecpg_build_compat_sqlda(int line, PGresult *res, int row, enum COMPAT_MODE compa
strcpy(fname, PQfname(res, i));
sqlda->sqlvar[i].sqlname = fname;
fname += strlen(sqlda->sqlvar[i].sqlname) + 1;
- /* this is reserved for future use, so we leave it empty for the time being */
- /* sqlda->sqlvar[i].sqlformat = (char *) (long) PQfformat(res, i);*/
+
+ /*
+ * this is reserved for future use, so we leave it empty for the time
+ * being
+ */
+ /* sqlda->sqlvar[i].sqlformat = (char *) (long) PQfformat(res, i); */
sqlda->sqlvar[i].sqlxid = PQftype(res, i);
sqlda->sqlvar[i].sqltypelen = PQfsize(res, i);
}
diff --git a/src/interfaces/ecpg/pgtypeslib/timestamp.c b/src/interfaces/ecpg/pgtypeslib/timestamp.c
index 3db57ad3cb0..8354e460d02 100644
--- a/src/interfaces/ecpg/pgtypeslib/timestamp.c
+++ b/src/interfaces/ecpg/pgtypeslib/timestamp.c
@@ -503,7 +503,7 @@ dttofmtasc_replace(timestamp * ts, date dDate, int dow, struct tm * tm,
case 'G':
{
/* Keep compiler quiet - Don't use a literal format */
- const char *fmt = "%G";
+ const char *fmt = "%G";
tm->tm_mon -= 1;
i = strftime(q, *pstr_len, fmt, tm);
@@ -689,7 +689,7 @@ dttofmtasc_replace(timestamp * ts, date dDate, int dow, struct tm * tm,
case 'V':
{
/* Keep compiler quiet - Don't use a literal format */
- const char *fmt = "%V";
+ const char *fmt = "%V";
i = strftime(q, *pstr_len, fmt, tm);
if (i == 0)
diff --git a/src/interfaces/libpq/fe-auth.c b/src/interfaces/libpq/fe-auth.c
index 9a0317ba4af..e72826cddc3 100644
--- a/src/interfaces/libpq/fe-auth.c
+++ b/src/interfaces/libpq/fe-auth.c
@@ -325,7 +325,7 @@ pg_GSS_error_int(PQExpBuffer str, const char *mprefix,
do
{
gss_display_status(&lmin_s, stat, type,
- GSS_C_NO_OID, &msg_ctx, &lmsg);
+ GSS_C_NO_OID, &msg_ctx, &lmsg);
appendPQExpBuffer(str, "%s: %s\n", mprefix, (char *) lmsg.value);
gss_release_buffer(&lmin_s, &lmsg);
} while (msg_ctx);
@@ -693,9 +693,9 @@ pg_local_sendauth(PGconn *conn)
struct cmsghdr *cmsg;
union
{
- struct cmsghdr hdr;
- unsigned char buf[CMSG_SPACE(sizeof(struct cmsgcred))];
- } cmsgbuf;
+ struct cmsghdr hdr;
+ unsigned char buf[CMSG_SPACE(sizeof(struct cmsgcred))];
+ } cmsgbuf;
/*
* The backend doesn't care what we send here, but it wants exactly one
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index 9aa6ca01eb2..9e4807e8a96 100644
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -1054,18 +1054,18 @@ connectFailureMessage(PGconn *conn, int errorno)
if ((conn->pghostaddr == NULL) &&
(conn->pghost == NULL || strcmp(conn->pghost, host_addr) != 0))
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("could not connect to server: %s\n"
- "\tIs the server running on host \"%s\" (%s) and accepting\n"
- "\tTCP/IP connections on port %s?\n"),
+ libpq_gettext("could not connect to server: %s\n"
+ "\tIs the server running on host \"%s\" (%s) and accepting\n"
+ "\tTCP/IP connections on port %s?\n"),
SOCK_STRERROR(errorno, sebuf, sizeof(sebuf)),
displayed_host,
host_addr,
conn->pgport);
else
appendPQExpBuffer(&conn->errorMessage,
- libpq_gettext("could not connect to server: %s\n"
- "\tIs the server running on host \"%s\" and accepting\n"
- "\tTCP/IP connections on port %s?\n"),
+ libpq_gettext("could not connect to server: %s\n"
+ "\tIs the server running on host \"%s\" and accepting\n"
+ "\tTCP/IP connections on port %s?\n"),
SOCK_STRERROR(errorno, sebuf, sizeof(sebuf)),
displayed_host,
conn->pgport);
@@ -1854,6 +1854,7 @@ keep_going: /* We will come back to here until there is
int packetlen;
#ifdef HAVE_UNIX_SOCKETS
+
/*
* Implement requirepeer check, if requested and it's a
* Unix-domain socket.
@@ -1870,14 +1871,17 @@ keep_going: /* We will come back to here until there is
errno = 0;
if (getpeereid(conn->sock, &uid, &gid) != 0)
{
- /* Provide special error message if getpeereid is a stub */
+ /*
+ * Provide special error message if getpeereid is a
+ * stub
+ */
if (errno == ENOSYS)
appendPQExpBuffer(&conn->errorMessage,
libpq_gettext("requirepeer parameter is not supported on this platform\n"));
else
appendPQExpBuffer(&conn->errorMessage,
libpq_gettext("could not get peer credentials: %s\n"),
- pqStrerror(errno, sebuf, sizeof(sebuf)));
+ pqStrerror(errno, sebuf, sizeof(sebuf)));
goto error_return;
}
@@ -1899,7 +1903,7 @@ keep_going: /* We will come back to here until there is
goto error_return;
}
}
-#endif /* HAVE_UNIX_SOCKETS */
+#endif /* HAVE_UNIX_SOCKETS */
#ifdef USE_SSL