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

Commite5532f1

Browse files
committed
Fix failures with TAP tests of pg_ctl on Windows
On Windows, all the hosts spawned by the TAP tests bind to 127.0.0.1.Hence, if there is a port conflict, starting a cluster would immediatelyfail. One of the test scripts of pg_ctl initializes a node withoutPostgresNode.pm, using the default port 5432. This could causeunexpected startup failures in the tests if an independent server was upand running on the same host (the reverse is also possible, though moreunlikely). Fix this issue by assigning properly a free port to the nodeconfigured, in the same range used as for the other nodes part of thetests.Author: Michael PaquierReviewed-by: Andrew DunstanDiscussion:https://postgr.es/m/20191202031444.GC1696@paquier.xyzBackpatch-through: 11
1 parent55a1954 commite5532f1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

‎src/bin/pg_ctl/t/001_start_stop.pl

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,10 @@
2222
'pg_ctl initdb');
2323
command_ok([$ENV{PG_REGRESS},'--config-auth',"$tempdir/data" ],
2424
'configure authentication');
25+
my$node_port = get_free_port();
2526
openmy$conf,'>>',"$tempdir/data/postgresql.conf";
2627
print$conf"fsync = off\n";
28+
print$conf"port =$node_port\n";
2729
print$conf TestLib::slurp_file($ENV{TEMP_CONFIG})
2830
ifdefined$ENV{TEMP_CONFIG};
2931

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp