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

Commit3be0a62

Browse files
committed
Finish pgindent run for 9.6: Perl files.
1 parentb098abf commit3be0a62

31 files changed

+1897
-2305
lines changed

‎contrib/bloom/t/001_wal.pl

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ sub test_index_replay
1616
# Wait for standby to catch up
1717
my$applname =$node_standby->name;
1818
my$caughtup_query =
19-
"SELECT pg_current_xlog_location() <= write_location FROM pg_stat_replication WHERE application_name = '$applname';";
19+
"SELECT pg_current_xlog_location() <= write_location FROM pg_stat_replication WHERE application_name = '$applname';";
2020
$node_master->poll_query_until('postgres',$caughtup_query)
2121
ordie"Timed out while waiting for standby 1 to catch up";
2222

@@ -56,20 +56,25 @@ sub test_index_replay
5656
# Create some bloom index on master
5757
$node_master->psql("postgres","CREATE EXTENSION bloom;");
5858
$node_master->psql("postgres","CREATE TABLE tst (i int4, t text);");
59-
$node_master->psql("postgres","INSERT INTO tst SELECT i%10, substr(md5(i::text), 1, 1) FROM generate_series(1,100000) i;");
60-
$node_master->psql("postgres","CREATE INDEX bloomidx ON tst USING bloom (i, t) WITH (col1 = 3);");
59+
$node_master->psql("postgres",
60+
"INSERT INTO tst SELECT i%10, substr(md5(i::text), 1, 1) FROM generate_series(1,100000) i;"
61+
);
62+
$node_master->psql("postgres",
63+
"CREATE INDEX bloomidx ON tst USING bloom (i, t) WITH (col1 = 3);");
6164

6265
# Test that queries give same result
6366
test_index_replay('initial');
6467

6568
# Run 10 cycles of table modification. Run test queries after each modification.
66-
formy$i (1..10)
69+
formy$i (1 ..10)
6770
{
6871
$node_master->psql("postgres","DELETE FROM tst WHERE i =$i;");
6972
test_index_replay("delete$i");
7073
$node_master->psql("postgres","VACUUM tst;");
7174
test_index_replay("vacuum$i");
7275
my ($start,$end) = (100001 + ($i - 1) * 10000, 100000 +$i * 10000);
73-
$node_master->psql("postgres","INSERT INTO tst SELECT i%10, substr(md5(i::text), 1, 1) FROM generate_series($start,$end) i;");
76+
$node_master->psql("postgres",
77+
"INSERT INTO tst SELECT i%10, substr(md5(i::text), 1, 1) FROM generate_series($start,$end) i;"
78+
);
7479
test_index_replay("insert$i");
7580
}

‎src/backend/storage/lmgr/generate-lwlocknames.pl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
use strict;
88

99
my$lastlockidx = -1;
10-
my$continue ="\n";
10+
my$continue="\n";
1111

1212
openmy$lwlocknames,$ARGV[0]ordie;
1313

@@ -18,7 +18,7 @@
1818
open C,'>',$ctmpordie"Could not open$ctmp:$!";
1919

2020
my$autogen =
21-
"/* autogenerated from src/backend/storage/lmgr/lwlocknames.txt, do not edit */\n";
21+
"/* autogenerated from src/backend/storage/lmgr/lwlocknames.txt, do not edit */\n";
2222
print H$autogen;
2323
print H"/* there is deliberately not an #ifndef LWLOCKNAMES_H here */\n\n";
2424
print C$autogen,"\n";
@@ -38,7 +38,7 @@
3838

3939
(my$lockname,my$lockidx) = ($1,$2);
4040

41-
die"lwlocknames.txt not in order"if$lockidx <$lastlockidx;
41+
die"lwlocknames.txt not in order"if$lockidx <$lastlockidx;
4242
die"lwlocknames.txt has duplicates"if$lockidx ==$lastlockidx;
4343

4444
while ($lastlockidx <$lockidx - 1)
@@ -49,7 +49,7 @@
4949
}
5050
printf C"%s\"%s\"",$continue,$lockname;
5151
$lastlockidx =$lockidx;
52-
$continue =",\n";
52+
$continue=",\n";
5353

5454
print H"#define$lockname (&MainLWLockArray[$lockidx].lock)\n";
5555
}

‎src/backend/utils/Gen_dummy_probes.pl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,7 @@ ()
224224
{
225225
if (ref($q))
226226
{
227+
227228
# flush open w files so that reading this file gets it all
228229
if (exists($wFiles{$$q}) &&$wFiles{$$q}ne'')
229230
{

‎src/backend/utils/mb/Unicode/UCS_to_SJIS.pl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@
5454
|| ( ($code >= 0x879a)
5555
&& ($code <= 0x879c)))
5656
{
57-
printfSTDERR
58-
"Warning: duplicate UTF8: UCS=0x%04x SJIS=0x%04x\n",$ucs,
57+
printfSTDERR"Warning: duplicate UTF8: UCS=0x%04x SJIS=0x%04x\n",
58+
$ucs,
5959
$code;
6060
next;
6161
}

‎src/bin/pg_basebackup/t/010_pg_basebackup.pl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@
114114
mkdir"$tempdir/tblspc1";
115115
$node->safe_psql('postgres',
116116
"CREATE TABLESPACE tblspc1 LOCATION '$shorter_tempdir/tblspc1';");
117-
$node->safe_psql('postgres',"CREATE TABLE test1 (a int) TABLESPACE tblspc1;");
117+
$node->safe_psql('postgres',
118+
"CREATE TABLE test1 (a int) TABLESPACE tblspc1;");
118119
$node->command_ok(['pg_basebackup','-D',"$tempdir/tarbackup2",'-Ft' ],
119120
'tar format with tablespaces');
120121
ok(-f"$tempdir/tarbackup2/base.tar",'backup tar was created');

‎src/bin/pg_dump/t/001_basic.pl

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,22 @@
2323
command_exit_is(['pg_dump','qqq','abc' ],
2424
1,'pg_dump: too many command-line arguments (first is "asd")');
2525

26-
command_exit_is(['pg_dump','-s','-a' ],
27-
1,'pg_dump: options -s/--schema-only and -a/--data-only cannot be used together');
28-
29-
command_exit_is(['pg_dump','-c','-a' ],
30-
1,'pg_dump: options -c/--clean and -a/--data-only cannot be used together');
31-
32-
command_exit_is(['pg_dump','--inserts','-o' ],
33-
1,'pg_dump: options --inserts/--column-inserts and -o/--oids cannot be used together');
26+
command_exit_is(
27+
['pg_dump','-s','-a' ],
28+
1,
29+
'pg_dump: options -s/--schema-only and -a/--data-only cannot be used together'
30+
);
31+
32+
command_exit_is(
33+
['pg_dump','-c','-a' ],
34+
1,
35+
'pg_dump: options -c/--clean and -a/--data-only cannot be used together');
36+
37+
command_exit_is(
38+
['pg_dump','--inserts','-o' ],
39+
1,
40+
'pg_dump: options --inserts/--column-inserts and -o/--oids cannot be used together'
41+
);
3442

3543
command_exit_is(['pg_dump','--if-exists' ],
3644
1,'pg_dump: option --if-exists requires option -c/--clean');

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp