Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Commit692bd09

Browse files
committed
Use "#ifdef CATALOG_VARLEN" to protect nullable fields of pg_authid.
This gives a stronger guarantee than a mere comment against accessing thesefields as simple struct members. Since rolpassword is in fact varlena,it's not clear why these didn't get marked from the beginning, but let'sdo it now.Michael Paquier
1 parent09d8d11 commit692bd09

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

‎src/include/catalog/pg_authid.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,10 @@ CATALOG(pg_authid,1260) BKI_SHARED_RELATION BKI_ROWTYPE_OID(2842) BKI_SCHEMA_MAC
5656
int32rolconnlimit;/* max connections allowed (-1=no limit) */
5757

5858
/* remaining fields may be null; use heap_getattr to read them! */
59+
#ifdefCATALOG_VARLEN/* variable-length fields start here */
5960
textrolpassword;/* password, if any */
6061
timestamptzrolvaliduntil;/* password expiration time, if any */
62+
#endif
6163
}FormData_pg_authid;
6264

6365
#undef timestamptz

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp