git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 94cb3fd)
Arrange for GRANT/REVOKE on a view to be dumped at the right time,
2001年7月29日 22:12:23 +0000 (22:12 +0000)
2001年7月29日 22:12:23 +0000 (22:12 +0000)
namely after the view definition rather than before it. Bug introduced
in 7.1 by changes to dump stuff in OID ordering.


diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c
index 783193751b023a741158362b9b7b0437c46a43d5..1a18bb223c4c425972fb68e623a2f642589f0fb4 100644 (file)
--- a/src/bin/pg_dump/pg_dump.c
+++ b/src/bin/pg_dump/pg_dump.c
@@ -22,7 +22,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.215 2001年07月17日 00:30:35 tgl Exp $
+ * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.216 2001年07月29日 22:12:23 tgl Exp $
*
* Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
*
@@ -3808,6 +3808,7 @@ dumpACL(Archive *fout, TableInfo tbinfo)
*tok,
*eqpos,
*priv;
+ char *objoid;
char *sql;
char tmp[1024];
int sSize = 4096;
@@ -3888,7 +3889,12 @@ dumpACL(Archive *fout, TableInfo tbinfo)
free(aclbuf);
- ArchiveEntry(fout, tbinfo.oid, tbinfo.relname, "ACL", NULL, sql, "", "", "", NULL, NULL);
+ if (tbinfo.viewdef != NULL)
+ objoid = tbinfo.viewoid;
+ else
+ objoid = tbinfo.oid;
+
+ ArchiveEntry(fout, objoid, tbinfo.relname, "ACL", NULL, sql, "", "", "", NULL, NULL);
}
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /