aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2009-03-13 22:50:44 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2009-03-13 22:50:44 +0000
commit0f80200a8e0692c39bdc0e6caa1809a63fa44fc8 (patch)
tree023f025cc16a59394f7cf79493a0921e9eb0c17e
parentd287c9eff0ba6e42f457ac71b07001f6e3ec3c90 (diff)
downloadpostgresql-0f80200a8e0692c39bdc0e6caa1809a63fa44fc8.tar.gz
postgresql-0f80200a8e0692c39bdc0e6caa1809a63fa44fc8.zip
Fix identify_locking_dependencies to reflect the fact that fix_dependencies
previously repointed TABLE dependencies to TABLE DATA. Mea culpa.
-rw-r--r--src/bin/pg_dump/pg_backup_archiver.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/bin/pg_dump/pg_backup_archiver.c b/src/bin/pg_dump/pg_backup_archiver.c
index 8cd171c2a90..148aca4ef6c 100644
--- a/src/bin/pg_dump/pg_backup_archiver.c
+++ b/src/bin/pg_dump/pg_backup_archiver.c
@@ -15,7 +15,7 @@
*
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/bin/pg_dump/pg_backup_archiver.c,v 1.166 2009/03/11 03:33:29 adunstan Exp $
+ * $PostgreSQL: pgsql/src/bin/pg_dump/pg_backup_archiver.c,v 1.167 2009/03/13 22:50:44 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -3732,8 +3732,11 @@ identify_locking_dependencies(TocEntry *te, TocEntry **tocsByDumpId)
return;
/*
- * We assume the item requires exclusive lock on each TABLE item
- * listed among its dependencies.
+ * We assume the item requires exclusive lock on each TABLE DATA item
+ * listed among its dependencies. (This was originally a dependency
+ * on the TABLE, but fix_dependencies repointed it to the data item.
+ * Note that all the entry types we are interested in here are POST_DATA,
+ * so they will all have been changed this way.)
*/
lockids = (DumpId *) malloc(te->nDeps * sizeof(DumpId));
nlockids = 0;
@@ -3742,7 +3745,7 @@ identify_locking_dependencies(TocEntry *te, TocEntry **tocsByDumpId)
DumpId depid = te->dependencies[i];
if (tocsByDumpId[depid - 1] &&
- strcmp(tocsByDumpId[depid - 1]->desc, "TABLE") == 0)
+ strcmp(tocsByDumpId[depid - 1]->desc, "TABLE DATA") == 0)
lockids[nlockids++] = depid;
}