aboutsummaryrefslogtreecommitdiff
path: root/src/test/perl/PostgresNode.pm
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2017-07-02 17:22:09 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2017-07-02 17:22:09 -0400
commitefdb4f29ba9ecbddb74d3a68577f068cf034c540 (patch)
treeb2461e2e0166b3b2677f5d080305e225afe9bd1b /src/test/perl/PostgresNode.pm
parent4e15387d2d9d4045efd1a7b3634e5922774139fd (diff)
downloadpostgresql-efdb4f29ba9ecbddb74d3a68577f068cf034c540.tar.gz
postgresql-efdb4f29ba9ecbddb74d3a68577f068cf034c540.zip
Fix bug in PostgresNode::query_hash's split() call.
By default, Perl's split() function drops trailing empty fields, which is not what we want here. Oversight in commit fb093e4cb. We'd managed to miss it thus far thanks to the very limited usage of this function. Discussion: https://postgr.es/m/14837.1499029831@sss.pgh.pa.us
Diffstat (limited to 'src/test/perl/PostgresNode.pm')
-rw-r--r--src/test/perl/PostgresNode.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/perl/PostgresNode.pm b/src/test/perl/PostgresNode.pm
index 4346423a0df..bb2f39e5089 100644
--- a/src/test/perl/PostgresNode.pm
+++ b/src/test/perl/PostgresNode.pm
@@ -1533,7 +1533,7 @@ sub query_hash
#
my %val;
@val{@columns} =
- $result ne '' ? split(qr/\|/, $result) : ('',) x scalar(@columns);
+ $result ne '' ? split(qr/\|/, $result, -1) : ('',) x scalar(@columns);
return \%val;
}