Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit99081c6

Browse files
committed
Improve connectMaintenanceDatabase() error reporting.
The prior coding instructs the user to pick an alternative maintenancedatabase, but this is overly clever, since it obscures whatever the realcause of the failure is.Josh Kupershmidt
1 parentaefa6d1 commit99081c6

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

‎src/bin/scripts/common.c

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -197,17 +197,7 @@ connectMaintenanceDatabase(const char *maintenance_db, const char *pghost,
197197
progname, true);
198198
if (!conn)
199199
conn=connectDatabase("template1",pghost,pgport,pguser,
200-
prompt_password,progname, true);
201-
202-
if (!conn)
203-
{
204-
fprintf(stderr,_("%s: could not connect to databases \"postgres\" or \"template1\"\n"
205-
"Please specify an alternative maintenance database.\n"),
206-
progname);
207-
fprintf(stderr,_("Try \"%s --help\" for more information.\n"),
208-
progname);
209-
exit(1);
210-
}
200+
prompt_password,progname, false);
211201

212202
returnconn;
213203
}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp