Author: twists
Date: Sat Jun 6 22:01:55 2009
New Revision: 755
Modified:
trunk/lib/Devel/NYTProf/Core.pm
Log:
Allow \ to escape things in NYTPROF environment variable
Modified: trunk/lib/Devel/NYTProf/Core.pm
==============================================================================
--- trunk/lib/Devel/NYTProf/Core.pm (original)
+++ trunk/lib/Devel/NYTProf/Core.pm Sat Jun 6 22:01:55 2009
@@ -19,8 +19,8 @@
XSLoader::load('Devel::NYTProf', $VERSION);
if (my $NYTPROF = $ENV{NYTPROF}) {
- for my $optval (split /:/, $NYTPROF) {
- my ($opt, $val) = split /=/, $optval, 2;
+ for my $optval ( $NYTPROF =~ /((?:[^\\:]+|\\.)+)/g) {#split /:/,
$NYTPROF) {
+ my ($opt, $val) = $optval =~ /^((?:[^\\=]+|\\.)+)=((?:[^\\=]+|
\\.)+)\z/;
DB::set_option($opt, $val);
}
}
--~--~---------~--~----~------------~-------~--~----~
You've received this message because you are subscribed to
the Devel::NYTProf Development User group.
Group hosted at: http://groups.google.com/group/develnytprof-dev
Project hosted at: http://perl-devel-nytprof.googlecode.com
CPAN distribution: http://search.cpan.org/dist/Devel-NYTProf
To post, email: [email protected]
To unsubscribe, email: [email protected]
-~----------~----~----~----~------~----~------~--~---