Skip Menu |

Preferred bug tracker

Please email the preferred bug tracker to report your issue.

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Term-ReadLine CPAN distribution.

Report information
The Basics
Id: 82263
Status: new
Priority: 0/
Queue: Term-ReadLine

People
Owner: Nobody in particular
Requestors: jeremy.mates [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: (no value)
Fixed in: (no value)



Subject: Term::ReadLine versus EOF char (^D)
cpan[1]> Use of uninitialized value in subroutine entry at /usr/libdata/perl5/Term/ReadLine.pm line 200. Use of uninitialized value in subroutine entry at /usr/libdata/perl5/Term/ReadLine.pm line 200. So the code takes the undef from ^D and then tries to utf8::upgrade it (line 200), so in theory somewhere before that there should be an is-undef-whoops-do-something case? sub readline { my $self = shift; my ($in,$out,$str) = @$self; my $prompt = shift; print $out $rl_term_set[0], $prompt, $rl_term_set[1], $rl_term_set[2]; $self->register_Tk if not $Term::ReadLine::registered and $Term::ReadLine::toloop and defined &Tk::DoOneEvent; #$str = scalar <$in>; $str = $self->get_line; $str =~ s/^\s*\Q$prompt\E// if ($^O eq 'MacOS'); utf8::upgrade($str) if (${^UNICODE} & PERL_UNICODE_STDIN || defined ${^ENCODING}) && utf8::valid($str); print $out $rl_term_set[3]; # bug in 5.000: chomping empty string creats length -1: chomp $str if defined $str; $str; }