Content-Length: 258773 | pFad | http://github.com/postgrespro/postgres_cluster/commit/0a49c95c734d58385e9c5e335088da1cd54e2344

70 Avoid incorrectly granting replication to roles created with NOSUPERU… · postgrespro/postgres_cluster@0a49c95 · GitHub
Skip to content

Commit 0a49c95

Browse files
committed
Avoid incorrectly granting replication to roles created with NOSUPERUSER.
Andres Freund
1 parent 40e6401 commit 0a49c95

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/backend/commands/user.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ CreateRole(CreateRoleStmt *stmt)
245245
* Superusers get replication by default, but only if NOREPLICATION
246246
* wasn't explicitly mentioned
247247
*/
248-
if (!(disreplication && intVal(disreplication->arg) == 0))
248+
if (issuper && !(disreplication && intVal(disreplication->arg) == 0))
249249
isreplication = 1;
250250
}
251251
if (dinherit)

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres_cluster/commit/0a49c95c734d58385e9c5e335088da1cd54e2344

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy