diff options
Diffstat (limited to 'src/bin/pg_dump/pg_dump.c')
| -rw-r--r-- | src/bin/pg_dump/pg_dump.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c index 63a82229fc..0397320a73 100644 --- 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.280 2002/08/04 05:03:29 momjian Exp $ + * $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.281 2002/08/10 16:57:31 petere Exp $ * *------------------------------------------------------------------------- */ @@ -480,16 +480,9 @@ main(int argc, char **argv) exit(1); } - /* Get the target database name */ + /* Get database name from command line */ if (optind < argc) dbname = argv[optind]; - else - dbname = getenv("PGDATABASE"); - if (!dbname) - { - write_msg(NULL, "no database name specified\n"); - exit(1); - } if (dataOnly && schemaOnly) { @@ -588,7 +581,7 @@ main(int argc, char **argv) if (g_fout->remoteVersion < 70300) { if (g_fout->remoteVersion >= 70100) - g_last_builtin_oid = findLastBuiltinOid_V71(dbname); + g_last_builtin_oid = findLastBuiltinOid_V71(PQdb(((ArchiveHandle *)g_conn)->connection)); else g_last_builtin_oid = findLastBuiltinOid_V70(); if (g_verbose) |
