mirror of
https://github.com/postgres/postgres.git
synced 2025-07-07 00:36:50 +03:00
Avoid incorrectly granting replication to roles created with NOSUPERUSER.
Andres Freund
This commit is contained in:
@ -245,7 +245,7 @@ CreateRole(CreateRoleStmt *stmt)
|
|||||||
* Superusers get replication by default, but only if NOREPLICATION
|
* Superusers get replication by default, but only if NOREPLICATION
|
||||||
* wasn't explicitly mentioned
|
* wasn't explicitly mentioned
|
||||||
*/
|
*/
|
||||||
if (!(disreplication && intVal(disreplication->arg) == 0))
|
if (issuper && !(disreplication && intVal(disreplication->arg) == 0))
|
||||||
isreplication = 1;
|
isreplication = 1;
|
||||||
}
|
}
|
||||||
if (dinherit)
|
if (dinherit)
|
||||||
|
Reference in New Issue
Block a user