aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/user.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/commands/user.c')
-rw-r--r--src/backend/commands/user.c50
1 files changed, 8 insertions, 42 deletions
diff --git a/src/backend/commands/user.c b/src/backend/commands/user.c
index 6796a1f5e29..c157ead4726 100644
--- a/src/backend/commands/user.c
+++ b/src/backend/commands/user.c
@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/backend/commands/user.c,v 1.187 2009/06/11 14:48:56 momjian Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/user.c,v 1.188 2009/09/01 02:54:51 alvherre Exp $
*
*-------------------------------------------------------------------------
*/
@@ -26,7 +26,6 @@
#include "storage/lmgr.h"
#include "utils/acl.h"
#include "utils/builtins.h"
-#include "utils/flatfiles.h"
#include "utils/fmgroids.h"
#include "utils/guc.h"
#include "utils/lsyscache.h"
@@ -385,15 +384,9 @@ CreateRole(CreateRoleStmt *stmt)
GetUserId(), false);
/*
- * Close pg_authid, but keep lock till commit (this is important to
- * prevent any risk of deadlock failure while updating flat file)
+ * Close pg_authid, but keep lock till commit.
*/
heap_close(pg_authid_rel, NoLock);
-
- /*
- * Set flag to update flat auth file at commit.
- */
- auth_file_update_needed();
}
@@ -710,15 +703,9 @@ AlterRole(AlterRoleStmt *stmt)
false);
/*
- * Close pg_authid, but keep lock till commit (this is important to
- * prevent any risk of deadlock failure while updating flat file)
+ * Close pg_authid, but keep lock till commit.
*/
heap_close(pg_authid_rel, NoLock);
-
- /*
- * Set flag to update flat auth file at commit.
- */
- auth_file_update_needed();
}
@@ -808,7 +795,6 @@ AlterRoleSet(AlterRoleSetStmt *stmt)
CatalogUpdateIndexes(rel, newtuple);
ReleaseSysCache(oldtuple);
- /* needn't keep lock since we won't be updating the flat file */
heap_close(rel, RowExclusiveLock);
}
@@ -970,16 +956,10 @@ DropRole(DropRoleStmt *stmt)
}
/*
- * Now we can clean up; but keep locks until commit (to avoid possible
- * deadlock failure while updating flat file)
+ * Now we can clean up; but keep locks until commit.
*/
heap_close(pg_auth_members_rel, NoLock);
heap_close(pg_authid_rel, NoLock);
-
- /*
- * Set flag to update flat auth file at commit.
- */
- auth_file_update_needed();
}
/*
@@ -1092,15 +1072,9 @@ RenameRole(const char *oldname, const char *newname)
ReleaseSysCache(oldtuple);
/*
- * Close pg_authid, but keep lock till commit (this is important to
- * prevent any risk of deadlock failure while updating flat file)
+ * Close pg_authid, but keep lock till commit.
*/
heap_close(rel, NoLock);
-
- /*
- * Set flag to update flat auth file at commit.
- */
- auth_file_update_needed();
}
/*
@@ -1157,15 +1131,9 @@ GrantRole(GrantRoleStmt *stmt)
}
/*
- * Close pg_authid, but keep lock till commit (this is important to
- * prevent any risk of deadlock failure while updating flat file)
+ * Close pg_authid, but keep lock till commit.
*/
heap_close(pg_authid_rel, NoLock);
-
- /*
- * Set flag to update flat auth file at commit.
- */
- auth_file_update_needed();
}
/*
@@ -1385,8 +1353,7 @@ AddRoleMems(const char *rolename, Oid roleid,
}
/*
- * Close pg_authmem, but keep lock till commit (this is important to
- * prevent any risk of deadlock failure while updating flat file)
+ * Close pg_authmem, but keep lock till commit.
*/
heap_close(pg_authmem_rel, NoLock);
}
@@ -1498,8 +1465,7 @@ DelRoleMems(const char *rolename, Oid roleid,
}
/*
- * Close pg_authmem, but keep lock till commit (this is important to
- * prevent any risk of deadlock failure while updating flat file)
+ * Close pg_authmem, but keep lock till commit.
*/
heap_close(pg_authmem_rel, NoLock);
}