postgres.git / summary / log / commit / refs
commit 962c14894768f95fabc82d4fb7db38c76d88fb97
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: Mon Mar 17 01:43:57 2014 +0000
First released in: 9.4.0, 8.4.21, 9.0.17, 9.1.13, 9.2.8, 9.3.4
Fix advertised dispsize for libpq's sslmode connection parameter.
"8" was correct back when "disable" was the longest allowed value, but
since "verify-full" was added, it should be "12". Given the lack of
complaints, I wouldn't be surprised if nobody is actually using these
values ... but still, if they're in the API, they should be right.
Noticed while pursuing a different problem. It's been wrong for quite
a long time, so back-patch to all supported branches.
src/interfaces/libpq/fe-connect.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/interfaces/libpq/fe-connect.c b/src/interfaces/libpq/fe-connect.c
index e0636167f4d..728e0fd106a 100644
--- a/src/interfaces/libpq/fe-connect.c
+++ b/src/interfaces/libpq/fe-connect.c
@@ -181,7 +181,7 @@ static const PQconninfoOption PQconninfoOptions[] = {
* to exclude them since none of them are mandatory.
*/
{"sslmode", "PGSSLMODE", DefaultSSLMode, NULL,
- "SSL-Mode", "", 8}, /* sizeof("disable") == 8 */
+ "SSL-Mode", "", 12}, /* sizeof("verify-full") == 12 */
{"sslcert", "PGSSLCERT", NULL, NULL,
"SSL-Client-Cert", "", 64},
[parent: 6e6c2c2e1e9f]