develooper Front page | perl.perl5.porters | Postings from December 2008

[perl #60972] Perl zero-length regex regular expression bug

Thread Previous | Thread Next
From:
James Mcclure
Date:
December 1, 2008 18:02
Subject:
[perl #60972] Perl zero-length regex regular expression bug
Message ID:
rt-3.6.HEAD-10965-1228164724-1933.60972-75-0@perl.org
# New Ticket Created by  James Mcclure 
# Please include the string:  [perl #60972]
# in the subject line of all future correspondence about this issue. 
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=60972 >


This is a bug report for perl from jamcclur@us.ibm.com,
generated with the help of perlbug 1.34 running under perl v5.8.0.

# perl zero-length regex bug

# instructions: 
#  1) run with $ARGV[0] = 1, this script prints false
#  2) run with $ARGV[0] = 2, this script prints true
#  3) comment out the $ARGV[0] =~ /1/ line --> this script prints true
$ARGV[0] =~ /1/;
if ( '' =~ // ) {  print "true\n"; }
else { print "false\n"; }
---
Flags:
    category=core
    severity=medium
---
Site configuration information for perl v5.8.0:

Configured by ActiveState at Fri Nov  8 00:53:50 2002.

Summary of my perl5 (revision 5 version 8 subversion 0) configuration:
  Platform:
    osname=MSWin32, osvers=4.0, archname=MSWin32-x86-multi-thread
    uname=''
    config_args='undef'
    hint=recommended, useposix=true, d_sigaction=undef
    usethreads=undef use5005threads=undef useithreads=define 
usemultiplicity=define
    useperlio=define d_sfio=undef uselargefiles=define usesocks=undef
    use64bitint=undef use64bitall=undef uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='cl', ccflags ='-nologo -Gf -W3 -MD -DNDEBUG -O1 -DWIN32 -D_CONSOLE 
-DNO_STRICT -DHAVE_DES_FCRYPT  -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS 
-DUSE_PERLIO -DPERL_MSVCRT_READFIX',
    optimize='-MD -DNDEBUG -O1',
    cppflags='-DWIN32'
    ccversion='', gccversion='', gccosandvers=''
    intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234
    d_longlong=undef, longlongsize=8, d_longdbl=define, longdblsize=10
    ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='__int64', 
lseeksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='link', ldflags ='-nologo -nodefaultlib -release 
-libpath:"C:/Perl\lib\CORE"  -machine:x86'
    libpth="" "C:\PROGRA~1\IBM\tdsdb2V9.1\LIB" "c:\Perl\lib\CORE"
    libs=  oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib 
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib  netapi32.lib 
uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib
    perllibs=  oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib 
 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib netapi32.lib 
uuid.lib wsock32.lib mpr.lib winmm.lib  version.lib odbc32.lib 
odbccp32.lib msvcrt.lib
    libc=msvcrt.lib, so=dll, useshrplib=yes, libperl=perl58.lib
    gnulibc_version='undef'
  Dynamic Linking:
    dlsrc=dl_win32.xs, dlext=dll, d_dlsymun=undef, ccdlflags=' '
    cccdlflags=' ', lddlflags='-dll -nologo -nodefaultlib -release 
-libpath:"C:/Perl\lib\CORE"  -machine:x86'

Locally applied patches:
    ACTIVEPERL_LOCAL_PATCHES_ENTRY

---
@INC for perl v5.8.0:
    c:/Perl/lib
    c:/Perl/site/lib
    .

---
Environment for perl v5.8.0:
    HOME (unset)
    LANG (unset)
    LANGUAGE (unset)
    LD_LIBRARY_PATH (unset)
    LOGDIR (unset)
 
PATH=c:\Perl\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program 
Files\IBM\Infoprint Select;C:\Notes;C:\Program 
Files\XLView;C:\lotus\compnent;C:\Utilities;C:\Program Files\IBM\Personal 
Communications\;C:\Program Files\IBM\Trace Facility\;C:\Program 
Files\Intel\Wireless\Bin\;C:\Program 
Files\ThinkPad\ConnectUtilities;C:\WINDOWS\Downloaded Program 
Files;C:\Program Files\IBM\CMVCDC50\bin;C:\Program Files\SlickEdit 
2008\win\;C:\Perl\bin;C:\Program Files\IBM\LDAP\V6.1\bin;C:\Program 
Files\IBM\LDAP\V6.1\sbin
    PERL_BADLANG (unset)
    SHELL (unset)
Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About