Bug#1040947: perl: readline fails to detect updated file

Eric Wong e at 80x24.org
Wed Jul 12 22:17:54 BST 2023


Package: perl
Version: 5.36.0-7
Severity: normal
Tags: upstream

Dear Maintainer,

The `readline' op (`<FH>') no longer detects updates to file
which is being written to in Perl 5.36.0 after updating to bookworm.

The attached script worked fine with Perl 5.32.1 in oldstable,
both scripts show the size changing with the `-s FH' op.
Same behavior on both amd64 and i386.


-- System Information:
Debian Release: 12.0
  APT prefers stable-security
  APT policy: (500, 'stable-security'), (500, 'stable-debug'), (500, 'stable')
Architecture: i386 (i686)

Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set to en_US.UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages perl depends on:
ii  dpkg               1.21.22
ii  libperl5.36        5.36.0-7
ii  perl-base          5.36.0-7
ii  perl-modules-5.36  5.36.0-7

Versions of packages perl recommends:
ii  netbase  6.4

Versions of packages perl suggests:
pn  libtap-harness-archive-perl                             <none>
pn  libterm-readline-gnu-perl | libterm-readline-perl-perl  <none>
ii  make                                                    4.3-4.1
ii  perl-doc                                                5.36.0-7

-- no debconf information
-------------- next part --------------
#!/usr/bin/perl -w
use v5.12;
use autodie;
use File::Temp;
use IO::Handle;
use Data::Dumper;
my $tmp = File::Temp->newdir('test-XXXX', TMPDIR => 1);
my $dst = "$tmp/log";
open my $wr, '>>', $dst;
open my $rd, '<', $dst;
say "# writing to $dst";
for my $n (1..5) {
	sleep 1;
	my @x = readline $rd;
	say "# size ".(-s $rd), ' ', Dumper(\@x);
	syswrite $wr, "$n\n";
}


More information about the Perl-maintainers mailing list