Bug#568317: perl: Executes every second $_ test only

Paul Szabo paul.szabo at sydney.edu.au
Wed Feb 3 21:31:09 UTC 2010


Package: perl
Version: 5.10.0-19lenny2
Severity: important



I noticed that /var/lib/dpkg/info/linux-image-*.postinst did not
correctly run lilo. Seems that the bug can be reproduced with script:


#! /usr/bin/perl

$_ = 'do_bootloader = yes';

#print "ctrl1\n";
print "test1\n" if /do_bootloader\s*=\s*(yes|true|1)\s*/ig;
#print "ctrl2\n";
print "test2\n" if /do_bootloader\s*=\s*(yes|true|1)\s*/ig;
#print "ctrl3\n";
print "test3\n" if /do_bootloader\s*=\s*(yes|true|1)\s*/ig;
#print "ctrl4\n";
print "test4\n" if /do_bootloader\s*=\s*(yes|true|1)\s*/ig;
#print "ctrl5\n";
print "test5\n" if /do_bootloader\s*=\s*(yes|true|1)\s*/ig;
#print "ctrl6\n";
print "test6\n" if /do_bootloader\s*=\s*(yes|true|1)\s*/ig;
exit;


which should print 6 tests, but it prints 1,3,5 only.
Uncommenting the control lines, those are printed correctly,
but still only tests 1,3,5 are printed.

Am I going mad ??!!

Thanks, Paul

Paul Szabo   psz at maths.usyd.edu.au   http://www.maths.usyd.edu.au/u/psz/
School of Mathematics and Statistics   University of Sydney    Australia


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

Kernel: Linux 2.6.26-pk03.15-svr (SMP w/8 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/bash

Versions of packages perl depends on:
ii  libc6                    2.7-18lenny2    GNU C Library: Shared libraries
ii  libdb4.6                 4.6.21-11       Berkeley v4.6 Database Libraries [
ii  libgdbm3                 1.8.3-3         GNU dbm database routines (runtime
ii  perl-base                5.10.0-19lenny2 minimal Perl system
ii  perl-modules             5.10.0-19lenny2 Core Perl modules

Versions of packages perl recommends:
ii  netbase                       4.34       Basic TCP/IP networking system

Versions of packages perl suggests:
pn  libterm-readline-gnu-per <none>          (no description available)
ii  perl-doc                 5.10.0-19lenny2 Perl documentation

-- no debconf information






More information about the Perl-maintainers mailing list