Skip to content

Commit 15bb93e

Browse files
committed
Fix portability problem in Catalog.pm.
Commit 7666e73 introduced a dependency on filehandles' input_line_number method, but apparently that's a Perl neologism. Use $. instead, which works at least back to Perl 5.10, and hopefully back to 5.8. Jeff Janes Discussion: https://postgr.es/m/CAMkU=1wuQW=xVfu-14A4VCvxO0ohkD3m9vk6HOj_dprQoKNAQw@mail.gmail.com
1 parent 395bfaa commit 15bb93e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/backend/catalog/Catalog.pm

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,9 @@ sub Catalogs
6666
redo;
6767
}
6868

69+
# Remember input line number for later.
70+
my $input_line_number = $.;
71+
6972
# Strip useless whitespace and trailing semicolons.
7073
chomp;
7174
s/^\s+//;
@@ -80,7 +83,7 @@ sub Catalogs
8083
elsif (/^DATA\(insert(\s+OID\s+=\s+(\d+))?\s+\(\s*(.*)\s*\)\s*\)$/)
8184
{
8285
check_natts($filename, $catalog{natts}, $3,
83-
$input_file, INPUT_FILE->input_line_number);
86+
$input_file, $input_line_number);
8487

8588
push @{ $catalog{data} }, { oid => $2, bki_values => $3 };
8689
}
@@ -242,4 +245,5 @@ sub check_natts
242245
$file, $line, $natts, scalar @atts
243246
unless $natts == @atts;
244247
}
248+
245249
1;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy