[strongSwan-dev] [PATCH 4/4] vici-perl: Do not "use warnings; " in modules.

Andreas Hofmeister andi at collax.com
Thu Dec 17 14:56:15 CET 2015


It is usually the calling script that enables (or does not enable) warnings
globally. When a module says "use warnings;" however, the caller looses control
over what warnings should be enabled in that module.
---
 src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Message.pm   | 1 -
 src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Packet.pm    | 1 -
 src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Session.pm   | 1 -
 src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Transport.pm | 1 -
 4 files changed, 4 deletions(-)

diff --git a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Message.pm b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Message.pm
index e30b691..b0a942c 100644
--- a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Message.pm
+++ b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Message.pm
@@ -3,7 +3,6 @@ package Vici::Message;
 our $VERSION = '0.9';
 
 use strict;
-use warnings;
 use Vici::Transport;
 
 use constant {
diff --git a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Packet.pm b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Packet.pm
index db22774..9e2b77f 100644
--- a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Packet.pm
+++ b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Packet.pm
@@ -3,7 +3,6 @@ package Vici::Packet;
 our $VERSION = '0.9';
 
 use strict;
-use warnings;
 use Vici::Message;
 use Vici::Transport;
 
diff --git a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Session.pm b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Session.pm
index 2ca2d82..5252296 100644
--- a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Session.pm
+++ b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Session.pm
@@ -3,7 +3,6 @@ package Vici::Session;
 our $VERSION = '0.9';
 
 use strict;
-use warnings;
 use Vici::Packet;
 use Vici::Message;
 
diff --git a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Transport.pm b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Transport.pm
index 41f35e0..6524bf7 100644
--- a/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Transport.pm
+++ b/src/libcharon/plugins/vici/perl/Vici-Session/lib/Vici/Transport.pm
@@ -3,7 +3,6 @@ package Vici::Transport;
 our $VERSION = '0.9';
 
 use strict;
-use warnings;
 
 sub new {
     my $class = shift;
-- 
2.6.2



More information about the Dev mailing list