git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 99b9928)
libpq: Some message style normalization
2024年6月13日 05:10:35 +0000 (07:10 +0200)
2024年6月13日 05:10:35 +0000 (07:10 +0200)

diff --git a/src/interfaces/libpq/fe-cancel.c b/src/interfaces/libpq/fe-cancel.c
index b183eafffad50a6ea23620145eafd3d462595ee1..3b6206ea7ffc014a5e2547031725d356c65840a7 100644 (file)
--- a/src/interfaces/libpq/fe-cancel.c
+++ b/src/interfaces/libpq/fe-cancel.c
@@ -73,13 +73,13 @@ PQcancelCreate(PGconn *conn)
/* Check we have an open connection */
if (!conn)
{
- libpq_append_conn_error(cancelConn, "passed connection was NULL");
+ libpq_append_conn_error(cancelConn, "connection pointer is NULL");
return (PGcancelConn *) cancelConn;
}
if (conn->sock == PGINVALID_SOCKET)
{
- libpq_append_conn_error(cancelConn, "passed connection is not open");
+ libpq_append_conn_error(cancelConn, "connection not open");
return (PGcancelConn *) cancelConn;
}
@@ -260,7 +260,7 @@ PQcancelPoll(PGcancelConn *cancelConn)
*/
if (n > 0)
{
- libpq_append_conn_error(conn, "received unexpected response from server");
+ libpq_append_conn_error(conn, "unexpected response from server");
conn->status = CONNECTION_BAD;
return PGRES_POLLING_FAILED;
}
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index 995621b6260ed2ff967829b8f8b44f5cdd4468b3..90f259fc70684e98ddd61f402e8a3ce68385bcb3 100644 (file)
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -1602,8 +1602,8 @@ pqConnectOptions2(PGconn *conn)
if (conn->sslnegotiation[0] != 'p')
{
conn->status = CONNECTION_BAD;
- libpq_append_conn_error(conn, "sslnegotiation value \"%s\" invalid when SSL support is not compiled in",
- conn->sslnegotiation);
+ libpq_append_conn_error(conn, "%s value \"%s\" invalid when SSL support is not compiled in",
+ "sslnegotiation", conn->sslnegotiation);
return false;
}
#endif
diff --git a/src/interfaces/libpq/fe-exec.c b/src/interfaces/libpq/fe-exec.c
index 7bdfc4c21aa3c35d12a9fbf122aeb24b5901c746..0d224a8524ed45b5fd719cecd41a4773fb48d2dc 100644 (file)
--- a/src/interfaces/libpq/fe-exec.c
+++ b/src/interfaces/libpq/fe-exec.c
@@ -2627,7 +2627,7 @@ PQsendTypedCommand(PGconn *conn, char command, char type, const char *target)
}
else
{
- libpq_append_conn_error(conn, "unknown command type provided");
+ libpq_append_conn_error(conn, "unrecognized message type \"%c\"", command);
goto sendFailed;
}
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /