Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 29e321c

Browse filesBrowse files
committed
Fix dispsize for libpq connection parameters channel_binding and gssencmode
channel_binding's longest allowed value is not "7", it is actually "8". gssencmode also got that wrong. A similar mistake has been fixed as of f4051e3. Backpatch down to v12, where gssencmode has been introduced. Reviewed-by: Daniel Gustafsson Discussion: https://postgr.es/m/20200128053633.GD1552@paquier.xyz Backpatch-through: 12
1 parent 47bc9ce commit 29e321c
Copy full SHA for 29e321c

File tree

Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed

‎src/interfaces/libpq/fe-connect.c

Copy file name to clipboardExpand all lines: src/interfaces/libpq/fe-connect.c
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ static const internalPQconninfoOption PQconninfoOptions[] = {
215215
offsetof(struct pg_conn, pgpassfile)},
216216

217217
{"channel_binding", "PGCHANNELBINDING", NULL, NULL,
218-
"Channel-Binding", "", 7, /* sizeof("require") */
218+
"Channel-Binding", "", 8, /* sizeof("require") == 8 */
219219
offsetof(struct pg_conn, channel_binding)},
220220

221221
{"connect_timeout", "PGCONNECT_TIMEOUT", NULL, NULL,
@@ -333,7 +333,7 @@ static const internalPQconninfoOption PQconninfoOptions[] = {
333333
* support.
334334
*/
335335
{"gssencmode", "PGGSSENCMODE", DefaultGSSMode, NULL,
336-
"GSSENC-Mode", "", 7, /* sizeof("disable") == 7 */
336+
"GSSENC-Mode", "", 8, /* sizeof("disable") == 8 */
337337
offsetof(struct pg_conn, gssencmode)},
338338

339339
/* Kerberos and GSSAPI authentication support specifying the service name */
@@ -342,7 +342,7 @@ static const internalPQconninfoOption PQconninfoOptions[] = {
342342
offsetof(struct pg_conn, krbsrvname)},
343343

344344
{"gsslib", "PGGSSLIB", NULL, NULL,
345-
"GSS-library", "", 7, /* sizeof("gssapi") = 7 */
345+
"GSS-library", "", 7, /* sizeof("gssapi") == 7 */
346346
offsetof(struct pg_conn, gsslib)},
347347

348348
{"replication", NULL, NULL, NULL,

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.