mschout / env-c Goto Github PK
View Code? Open in Web Editor NEWGet/Set/Unset Environment Variables on the C level
License: Other
Get/Set/Unset Environment Variables on the C level
License: Other
https://rt.cpan.org/Ticket/Display.html?id=49872
If you use Env::C in the following constellation, you will get a
continues growing memory usage:
<!------------------------------------------->
#!/usr/bin/perl
sub BEGIN
{
eval('use Env::C;');
eval('Env::C::setenv("TZ","GMT",1);');
}
for(my $cc=0;$cc<100;$cc++){
for(my $c=0;$c<1000;$c++){
$ENV{TZ}="GMT";
$ENV{TZ}="";
}
printf("Check loop $cc\n");
sleep(1);
}
<!------------------------------------------->
The problem seems to be only happen, if you use the Env::C as eval in
the BEGIN block.
This module does not include a META.json file, despite including the [MetaJSON]
plugin for Dist::Zilla, as reported by CPANTS. Any idea why this might be?
I tried to examine this issue locally, but I was unable to install the author dependencies (although that is probably be a problem with [ArchiveRelease]
, which is used by your plugin bundle).
Hello,
A test in leak.t failed with the following:
# Failed test 'setenv does not leak'
# at t/leak.t line 31.
# got: 5576
# expected: 5578
# Looks like you failed 1 test of 1.
t/leak.t ..................
Happens upon installing via cpanm on an Debian 7.9 (Wheezy):
$ > apt-cache show libc6
Package: libc6
Source: eglibc
Version: 2.13-38+deb7u10
See build.txt for full build log.
Things works fine on:
I got a test failure similar to this one: http://www.cpantesters.org/cpan/report/454cc6e4-6c00-1014-9d53-b5a8b734fec4
It seems that line 38, variable names in @perl_env are all upper-case (that's probably how perl handles env variables on windows ), but in @$env the names are raw like what's seen from the "set" command in a console. So the names are different and after sort the sequences also become different.
is_deeply [sort @$env], [sort @perl_env];
It could be better to check $^O and for Windows change @$env var names to upper-case before sort. As cygwin does not have this issue, may need to distinguish cygwin from native Windows console, or simply do upper-case to var names in both @$env and @perl_env.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.