develooper Front page | perl.perl5.porters | Postings from June 2016

[perl #128313] Memory leak in perl 5.24.0 when use re qw[strict] isused

From:
zdm @ softvisio . net
Date:
June 3, 2016 14:47
Subject:
[perl #128313] Memory leak in perl 5.24.0 when use re qw[strict] isused
Message ID:
rt-4.0.18-16638-1464952060-393.128313-75-0@perl.org
# New Ticket Created by  zdm@softvisio.net 
# Please include the string:  [perl #128313]
# in the subject line of all future correspondence about this issue. 
# <URL: https://rt.perl.org/Ticket/Display.html?id=128313 >


Reply-To: zdm@softvisio.net
From: zdm@softvisio.net
Message-Id: <5.24.0_3968_1464951615@WIN-OPJJ674O0JK>
To: perlbug@perl.org
Subject: Memory leak in perl 5.24.0 when use re qw[strict] is used


This is a bug report for perl from zdm@softvisio.net,
generated with the help of perlbug 1.40 running under perl 5.24.0.


-----------------------------------------------------------------

Hi.

This code produce memory leak:

use re qw[strict];
my $s = 'aaa';
while (1) {
    my $ps = 'aa';
    $s =~ /[^.]+\.$ps\z/sm;
}

If I remove "use re qw[strict];" - mem. leak disappearing.



[Please do not change anything below this line]
-----------------------------------------------------------------
---
Flags:
    category=core
    severity=high
---
Site configuration information for perl 5.24.0:

Configured by strawberry-perl at Tue May 10 21:33:22 2016.

Summary of my perl5 (revision 5 version 24 subversion 0) configuration:

  Platform:
    osname=MSWin32, osvers=6.3, archname=MSWin32-x64-multi-thread
    uname='Win32 strawberry-perl 5.24.0.1 #1 Tue May 10 21:30:49 2016 x64'
    config_args='undef'
    hint=recommended, useposix=true, d_sigaction=undef
    useithreads=define, usemultiplicity=define
    use64bitint=define, use64bitall=undef, uselongdouble=undef
    usemymalloc=n, bincompat5005=undef
  Compiler:
    cc='gcc', ccflags =' -s -O2 -DWIN32 -DWIN64 -DCONSERVATIVE
-DPERL_TEXTMODE_SCRIPTS -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS
-fwrapv -fno-strict-aliasing -mms-bitfields',
    optimize='-s -O2',
    cppflags='-DWIN32'
    ccversion='', gccversion='4.9.2', gccosandvers=''
    intsize=4, longsize=4, ptrsize=8, doublesize=8, byteorder=12345678,
doublekind=3
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16,
longdblkind=3
    ivtype='long long', ivsize=8, nvtype='double', nvsize=8, Off_t='long
long', lseeksize=8
    alignbytes=8, prototype=define
  Linker and Libraries:
    ld='g++.exe', ldflags ='-s -L"D:\devel\perl\perl\lib\CORE"
-L"D:\devel\perl\c\lib"'
    libpth=D:\devel\perl\c\lib D:\devel\perl\c\x86_64-w64-mingw32\lib
D:\devel\perl\c\lib\gcc\x86_64-w64-mingw32\4.9.2
    libs=-lmoldname -lkernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32
-ladvapi32 -lshell32 -lole32 -loleaut32 -lnetapi32 -luuid -lws2_32 -lmpr
-lwinmm -lversion -lodbc32 -lodbccp32 -lcomctl32
    perllibs=-lmoldname -lkernel32 -luser32 -lgdi32 -lwinspool
-lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -lnetapi32 -luuid
-lws2_32 -lmpr -lwinmm -lversion -lodbc32 -lodbccp32 -lcomctl32
    libc=, so=dll, useshrplib=true, libperl=libperl524.a
    gnulibc_version=''
  Dynamic Linking:
    dlsrc=dl_win32.xs, dlext=xs.dll, d_dlsymun=undef, ccdlflags=' '
    cccdlflags=' ', lddlflags='-mdll -s -L"D:\devel\perl\perl\lib\CORE"
-L"D:\devel\perl\c\lib"'


---
@INC for perl 5.24.0:
    d:/projects/pcore/lib
    d:/devel/perl/perl/site/lib/MSWin32-x64-multi-thread
    d:/devel/perl/perl/site/lib
    d:/devel/perl/perl/vendor/lib
    d:/devel/perl/perl/lib
    .

---
Environment for perl 5.24.0:
    HOME (unset)
    LANG=en_US
    LANGUAGE (unset)
    LD_LIBRARY_PATH (unset)
    LOGDIR (unset)

PATH=C:\Windows;C:\Windows\system32;C:\Windows\system32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;d:\apps\bin;d:\apps\gpg;d:\devel\bin;d:\devel\perl\perl\site\bin;d:\devel\perl\perl\bin;d:\devel\perl\c\bin;d:\devel\hg;d:\devel\jre\bin;d:\devel\sencha\sencha-cmd;d:\devel\nodejs;d:\devel\msys2\usr\bin;d:\projects\pcore\bin;;d:/data
    PERL5LIB=d:/projects/pcore/lib;
    PERL_BADLANG (unset)
    SHELL (unset)




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