diff options
author | Karl Berry <karl@freefriends.org> | 2015-04-26 22:16:26 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2015-04-26 22:16:26 +0000 |
commit | 342e672574c4e67d510e46ab6acd0e21a7d0cf54 (patch) | |
tree | 79e04202d08c0404bbd780bd26c1e34710e539b6 /Master/tlpkg/tlperl/lib/URI | |
parent | be2706af7c57a0ef0f4d4e9f684ca4ef74922a82 (diff) |
(tl)perl 5.20.2 for windows, from siep
git-svn-id: svn://tug.org/texlive/trunk@37064 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/tlpkg/tlperl/lib/URI')
51 files changed, 221 insertions, 153 deletions
diff --git a/Master/tlpkg/tlperl/lib/URI/Escape.pm b/Master/tlpkg/tlperl/lib/URI/Escape.pm index e09d76acc48..547535ea801 100644 --- a/Master/tlpkg/tlperl/lib/URI/Escape.pm +++ b/Master/tlpkg/tlperl/lib/URI/Escape.pm @@ -1,5 +1,7 @@ package URI::Escape; + use strict; +use warnings; =head1 NAME @@ -135,8 +137,7 @@ it under the same terms as Perl itself. =cut -require Exporter; -our @ISA = qw(Exporter); +use Exporter 'import'; our %escapes; our @EXPORT = qw(uri_escape uri_unescape uri_escape_utf8); our @EXPORT_OK = qw(%escapes); @@ -201,8 +202,19 @@ sub uri_unescape { $str; } +# XXX FIXME escape_char is buggy as it assigns meaning to the string's storage format. sub escape_char { - return join '', @URI::Escape::escapes{$_[0] =~ /(\C)/g}; + # Old versions of utf8::is_utf8() didn't properly handle magical vars (e.g. $1). + # The following forces a fetch to occur beforehand. + my $dummy = substr($_[0], 0, 0); + + if (utf8::is_utf8($_[0])) { + my $s = shift; + utf8::encode($s); + unshift(@_, $s); + } + + return join '', @URI::Escape::escapes{split //, $_[0]}; } 1; diff --git a/Master/tlpkg/tlperl/lib/URI/Heuristic.pm b/Master/tlpkg/tlperl/lib/URI/Heuristic.pm index 71ad8dab8ff..89ec7bd5c33 100644 --- a/Master/tlpkg/tlperl/lib/URI/Heuristic.pm +++ b/Master/tlpkg/tlperl/lib/URI/Heuristic.pm @@ -87,13 +87,13 @@ modify it under the same terms as Perl itself. =cut use strict; +use warnings; -use vars qw(@EXPORT_OK $VERSION $MY_COUNTRY %LOCAL_GUESSING $DEBUG); +use Exporter 'import'; +our @EXPORT_OK = qw(uf_uri uf_uristr uf_url uf_urlstr); +our $VERSION = "4.20"; -require Exporter; -*import = \&Exporter::import; -@EXPORT_OK = qw(uf_uri uf_uristr uf_url uf_urlstr); -$VERSION = "4.20"; +our ($MY_COUNTRY, $DEBUG); sub MY_COUNTRY() { for ($MY_COUNTRY) { @@ -131,7 +131,7 @@ sub MY_COUNTRY() { } } -%LOCAL_GUESSING = +our %LOCAL_GUESSING = ( 'us' => [qw(www.ACME.gov www.ACME.mil)], 'gb' => [qw(www.ACME.co.uk www.ACME.org.uk www.ACME.ac.uk)], diff --git a/Master/tlpkg/tlperl/lib/URI/IRI.pm b/Master/tlpkg/tlperl/lib/URI/IRI.pm index 39336fce5ac..8ce51912cc8 100644 --- a/Master/tlpkg/tlperl/lib/URI/IRI.pm +++ b/Master/tlpkg/tlperl/lib/URI/IRI.pm @@ -3,6 +3,7 @@ package URI::IRI; # Experimental use strict; +use warnings; use URI (); use overload '""' => sub { shift->as_string }; @@ -27,9 +28,9 @@ sub as_string { return $self->{uri}->as_iri; } +our $AUTOLOAD; sub AUTOLOAD { - use vars qw($AUTOLOAD); my $method = substr($AUTOLOAD, rindex($AUTOLOAD, '::')+2); # We create the function here so that it will not need to be diff --git a/Master/tlpkg/tlperl/lib/URI/QueryParam.pm b/Master/tlpkg/tlperl/lib/URI/QueryParam.pm index c202feabfab..187cd2c6396 100644 --- a/Master/tlpkg/tlperl/lib/URI/QueryParam.pm +++ b/Master/tlpkg/tlperl/lib/URI/QueryParam.pm @@ -1,6 +1,7 @@ package URI::QueryParam; use strict; +use warnings; sub URI::_query::query_param { my $self = shift; diff --git a/Master/tlpkg/tlperl/lib/URI/Split.pm b/Master/tlpkg/tlperl/lib/URI/Split.pm index ad430b93277..70ff17ae620 100644 --- a/Master/tlpkg/tlperl/lib/URI/Split.pm +++ b/Master/tlpkg/tlperl/lib/URI/Split.pm @@ -1,11 +1,10 @@ package URI::Split; use strict; +use warnings; -use vars qw(@ISA @EXPORT_OK); -require Exporter; -@ISA = qw(Exporter); -@EXPORT_OK = qw(uri_split uri_join); +use Exporter 'import'; +our @EXPORT_OK = qw(uri_split uri_join); use URI::Escape (); diff --git a/Master/tlpkg/tlperl/lib/URI/URL.pm b/Master/tlpkg/tlperl/lib/URI/URL.pm index 81bf47d3af1..867ac6a9d5d 100644 --- a/Master/tlpkg/tlperl/lib/URI/URL.pm +++ b/Master/tlpkg/tlperl/lib/URI/URL.pm @@ -1,19 +1,17 @@ package URI::URL; -require URI::WithBase; -@ISA=qw(URI::WithBase); - use strict; -use vars qw(@EXPORT $VERSION); +use warnings; + +use parent 'URI::WithBase'; -$VERSION = "5.04"; +our $VERSION = "5.04"; # Provide as much as possible of the old URI::URL interface for backwards # compatibility... -require Exporter; -*import = \&Exporter::import; -@EXPORT = qw(url); +use Exporter 'import'; +our @EXPORT = qw(url); # Easy to use constructor sub url ($;$) { URI::URL->new(@_); } @@ -105,7 +103,7 @@ sub eparams { my $self = shift; my @p = $self->path_segments; - return unless ref($p[-1]); + return undef unless ref($p[-1]); @p = @{$p[-1]}; shift @p; join(";", @p); @@ -144,7 +142,7 @@ sub query { Carp::croak("$mess (you must call equery)"); } } - # Now it should be safe to unescape the string without loosing + # Now it should be safe to unescape the string without losing # information return uri_unescape($old); } diff --git a/Master/tlpkg/tlperl/lib/URI/WithBase.pm b/Master/tlpkg/tlperl/lib/URI/WithBase.pm index 4300a2a60ae..943b7b533a7 100644 --- a/Master/tlpkg/tlperl/lib/URI/WithBase.pm +++ b/Master/tlpkg/tlperl/lib/URI/WithBase.pm @@ -1,10 +1,12 @@ package URI::WithBase; use strict; -use vars qw($AUTOLOAD $VERSION); +use warnings; + use URI; +use Scalar::Util 'blessed'; -$VERSION = "2.20"; +our $VERSION = "2.20"; use overload '""' => "as_string", fallback => 1; @@ -14,7 +16,7 @@ sub new { my($class, $uri, $base) = @_; my $ibase = $base; - if ($base && ref($base) && UNIVERSAL::isa($base, __PACKAGE__)) { + if ($base && blessed($base) && $base->isa(__PACKAGE__)) { $base = $base->abs; $ibase = $base->[0]; } @@ -38,10 +40,11 @@ sub _init sub eq { my($self, $other) = @_; - $other = $other->[0] if UNIVERSAL::isa($other, __PACKAGE__); + $other = $other->[0] if blessed($other) and $other->isa(__PACKAGE__); $self->[0]->eq($other); } +our $AUTOLOAD; sub AUTOLOAD { my $self = shift; diff --git a/Master/tlpkg/tlperl/lib/URI/_foreign.pm b/Master/tlpkg/tlperl/lib/URI/_foreign.pm index 075f0fd3417..0132efeb8f5 100644 --- a/Master/tlpkg/tlperl/lib/URI/_foreign.pm +++ b/Master/tlpkg/tlperl/lib/URI/_foreign.pm @@ -1,6 +1,8 @@ package URI::_foreign; -require URI::_generic; -@ISA=qw(URI::_generic); +use strict; +use warnings; + +use parent 'URI::_generic'; 1; diff --git a/Master/tlpkg/tlperl/lib/URI/_generic.pm b/Master/tlpkg/tlperl/lib/URI/_generic.pm index 979087b6301..ce1e03d882d 100644 --- a/Master/tlpkg/tlperl/lib/URI/_generic.pm +++ b/Master/tlpkg/tlperl/lib/URI/_generic.pm @@ -1,9 +1,10 @@ package URI::_generic; -require URI; -require URI::_query; -@ISA=qw(URI URI::_query); use strict; +use warnings; + +use parent qw(URI URI::_query); + use URI::Escape qw(uri_unescape); use Carp (); @@ -148,7 +149,8 @@ sub abs my $abs = $base->clone; my $query = $self->query; $abs->query($query) if defined $query; - $abs->fragment($self->fragment); + my $fragment = $self->fragment; + $abs->fragment($fragment) if defined $fragment; return $abs; } diff --git a/Master/tlpkg/tlperl/lib/URI/_idna.pm b/Master/tlpkg/tlperl/lib/URI/_idna.pm index 8b9eab7cb11..be0cccf16b3 100644 --- a/Master/tlpkg/tlperl/lib/URI/_idna.pm +++ b/Master/tlpkg/tlperl/lib/URI/_idna.pm @@ -4,6 +4,8 @@ package URI::_idna; # based on Python-2.6.4/Lib/encodings/idna.py use strict; +use warnings; + use URI::_punycode qw(encode_punycode decode_punycode); use Carp qw(croak); diff --git a/Master/tlpkg/tlperl/lib/URI/_ldap.pm b/Master/tlpkg/tlperl/lib/URI/_ldap.pm index d76736471d4..d273f32d6f3 100644 --- a/Master/tlpkg/tlperl/lib/URI/_ldap.pm +++ b/Master/tlpkg/tlperl/lib/URI/_ldap.pm @@ -5,9 +5,9 @@ package URI::_ldap; use strict; +use warnings; -use vars qw($VERSION); -$VERSION = "1.12"; +our $VERSION = "1.67"; use URI::Escape qw(uri_unescape); @@ -47,7 +47,7 @@ sub attributes { sub _scope { my $self = shift; my $old = _ldap_elem($self,1, @_); - return unless defined wantarray && defined $old; + return undef unless defined wantarray && defined $old; uri_unescape($old); } @@ -60,7 +60,7 @@ sub scope { sub _filter { my $self = shift; my $old = _ldap_elem($self,2, @_); - return unless defined wantarray && defined $old; + return undef unless defined wantarray && defined $old; uri_unescape($old); # || "(objectClass=*)"; } diff --git a/Master/tlpkg/tlperl/lib/URI/_login.pm b/Master/tlpkg/tlperl/lib/URI/_login.pm index 4583f20a9a6..83855a835ac 100644 --- a/Master/tlpkg/tlperl/lib/URI/_login.pm +++ b/Master/tlpkg/tlperl/lib/URI/_login.pm @@ -1,8 +1,9 @@ package URI::_login; -require URI::_server; -require URI::_userpass; -@ISA = qw(URI::_server URI::_userpass); +use strict; +use warnings; + +use parent qw(URI::_server URI::_userpass); # Generic terminal logins. This is used as a base class for 'telnet', # 'tn3270', and 'rlogin' URL schemes. diff --git a/Master/tlpkg/tlperl/lib/URI/_punycode.pm b/Master/tlpkg/tlperl/lib/URI/_punycode.pm index db400914268..bd69fe7377a 100644 --- a/Master/tlpkg/tlperl/lib/URI/_punycode.pm +++ b/Master/tlpkg/tlperl/lib/URI/_punycode.pm @@ -1,10 +1,11 @@ package URI::_punycode; use strict; -our $VERSION = "0.04"; +use warnings; -require Exporter; -our @ISA = qw(Exporter); +our $VERSION = "1.67"; + +use Exporter 'import'; our @EXPORT = qw(encode_punycode decode_punycode); use integer; diff --git a/Master/tlpkg/tlperl/lib/URI/_query.pm b/Master/tlpkg/tlperl/lib/URI/_query.pm index a6038a3717a..93288ca770c 100644 --- a/Master/tlpkg/tlperl/lib/URI/_query.pm +++ b/Master/tlpkg/tlperl/lib/URI/_query.pm @@ -1,6 +1,8 @@ package URI::_query; use strict; +use warnings; + use URI (); use URI::Escape qw(uri_unescape); @@ -88,6 +90,6 @@ sub query_keywords } # Some URI::URL compatibility stuff -*equery = \&query; +sub equery { goto &query } 1; diff --git a/Master/tlpkg/tlperl/lib/URI/_segment.pm b/Master/tlpkg/tlperl/lib/URI/_segment.pm index c91b69608e3..2c42fc15925 100644 --- a/Master/tlpkg/tlperl/lib/URI/_segment.pm +++ b/Master/tlpkg/tlperl/lib/URI/_segment.pm @@ -4,6 +4,8 @@ package URI::_segment; # a string too. use strict; +use warnings; + use URI::Escape qw(uri_unescape); use overload '""' => sub { $_[0]->[0] }, diff --git a/Master/tlpkg/tlperl/lib/URI/_server.pm b/Master/tlpkg/tlperl/lib/URI/_server.pm index f72ec22657b..643d13e1bc9 100644 --- a/Master/tlpkg/tlperl/lib/URI/_server.pm +++ b/Master/tlpkg/tlperl/lib/URI/_server.pm @@ -1,8 +1,10 @@ package URI::_server; -require URI::_generic; -@ISA=qw(URI::_generic); use strict; +use warnings; + +use parent 'URI::_generic'; + use URI::Escape qw(uri_unescape); sub _uric_escape { @@ -19,7 +21,7 @@ sub _uric_escape { } sub _host_escape { - return unless $_[0] =~ /[^URI::uric]/; + return unless $_[0] =~ /[^$URI::uric]/; eval { require URI::_idna; $_[0] = URI::_idna::encode($_[0]); diff --git a/Master/tlpkg/tlperl/lib/URI/_userpass.pm b/Master/tlpkg/tlperl/lib/URI/_userpass.pm index a0361ae0dd7..db8b53b5262 100644 --- a/Master/tlpkg/tlperl/lib/URI/_userpass.pm +++ b/Master/tlpkg/tlperl/lib/URI/_userpass.pm @@ -1,6 +1,8 @@ package URI::_userpass; use strict; +use warnings; + use URI::Escape qw(uri_unescape); sub user @@ -21,7 +23,7 @@ sub user $self->userinfo("$new$pass"); } } - return unless defined $info; + return undef unless defined $info; $info =~ s/:.*//; uri_unescape($info); } @@ -43,8 +45,8 @@ sub password $self->userinfo("$user:$new"); } } - return unless defined $info; - return unless $info =~ s/^[^:]*://; + return undef unless defined $info; + return undef unless $info =~ s/^[^:]*://; uri_unescape($info); } diff --git a/Master/tlpkg/tlperl/lib/URI/data.pm b/Master/tlpkg/tlperl/lib/URI/data.pm index dccd8181289..19c390ec03c 100644 --- a/Master/tlpkg/tlperl/lib/URI/data.pm +++ b/Master/tlpkg/tlperl/lib/URI/data.pm @@ -1,9 +1,11 @@ package URI::data; # RFC 2397 -require URI; -@ISA=qw(URI); - use strict; +use warnings; + +use parent 'URI'; + +our $VERSION = '1.67'; use MIME::Base64 qw(encode_base64 decode_base64); use URI::Escape qw(uri_unescape); diff --git a/Master/tlpkg/tlperl/lib/URI/file.pm b/Master/tlpkg/tlperl/lib/URI/file.pm index 5a1e2b530be..d76ddf2b5e2 100644 --- a/Master/tlpkg/tlperl/lib/URI/file.pm +++ b/Master/tlpkg/tlperl/lib/URI/file.pm @@ -1,19 +1,18 @@ package URI::file; use strict; -use vars qw(@ISA $VERSION $DEFAULT_AUTHORITY %OS_CLASS); +use warnings; -require URI::_generic; -@ISA = qw(URI::_generic); -$VERSION = "4.21"; +use parent 'URI::_generic'; +our $VERSION = "4.21"; use URI::Escape qw(uri_unescape); -$DEFAULT_AUTHORITY = ""; +our $DEFAULT_AUTHORITY = ""; # Map from $^O values to implementation classes. The Unix # class is the default. -%OS_CLASS = ( +our %OS_CLASS = ( os2 => "OS2", mac => "Mac", MacOS => "Mac", diff --git a/Master/tlpkg/tlperl/lib/URI/file/Base.pm b/Master/tlpkg/tlperl/lib/URI/file/Base.pm index 941793b0f93..bba1c9dbf6a 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/Base.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/Base.pm @@ -1,6 +1,8 @@ package URI::file::Base; use strict; +use warnings; + use URI::Escape qw(); sub new diff --git a/Master/tlpkg/tlperl/lib/URI/file/FAT.pm b/Master/tlpkg/tlperl/lib/URI/file/FAT.pm index 328169bd0bf..212d1abd1a2 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/FAT.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/FAT.pm @@ -1,7 +1,9 @@ package URI::file::FAT; -require URI::file::Win32; -@ISA=qw(URI::file::Win32); +use strict; +use warnings; + +use parent 'URI::file::Win32'; sub fix_path { diff --git a/Master/tlpkg/tlperl/lib/URI/file/Mac.pm b/Master/tlpkg/tlperl/lib/URI/file/Mac.pm index 6cfa78192e0..1cf08f5d4ad 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/Mac.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/Mac.pm @@ -1,9 +1,10 @@ package URI::file::Mac; -require URI::file::Base; -@ISA=qw(URI::file::Base); - use strict; +use warnings; + +use parent 'URI::file::Base'; + use URI::Escape qw(uri_unescape); diff --git a/Master/tlpkg/tlperl/lib/URI/file/OS2.pm b/Master/tlpkg/tlperl/lib/URI/file/OS2.pm index ad0a78ede52..a301468a68f 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/OS2.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/OS2.pm @@ -1,7 +1,9 @@ package URI::file::OS2; -require URI::file::Win32; -@ISA=qw(URI::file::Win32); +use strict; +use warnings; + +use parent 'URI::file::Win32'; # The Win32 version translates k:/foo to file://k:/foo (?!) # We add an empty host diff --git a/Master/tlpkg/tlperl/lib/URI/file/QNX.pm b/Master/tlpkg/tlperl/lib/URI/file/QNX.pm index 93a4983d2bb..ccdb1813598 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/QNX.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/QNX.pm @@ -1,9 +1,9 @@ package URI::file::QNX; -require URI::file::Unix; -@ISA=qw(URI::file::Unix); - use strict; +use warnings; + +use parent 'URI::file::Unix'; sub _file_extract_path { diff --git a/Master/tlpkg/tlperl/lib/URI/file/Unix.pm b/Master/tlpkg/tlperl/lib/URI/file/Unix.pm index 5f8aaae9050..4315c3ea8b8 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/Unix.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/Unix.pm @@ -1,9 +1,10 @@ package URI::file::Unix; -require URI::file::Base; -@ISA=qw(URI::file::Base); - use strict; +use warnings; + +use parent 'URI::file::Base'; + use URI::Escape qw(uri_unescape); sub _file_extract_path diff --git a/Master/tlpkg/tlperl/lib/URI/file/Win32.pm b/Master/tlpkg/tlperl/lib/URI/file/Win32.pm index 04593863a92..7762d2a910b 100644 --- a/Master/tlpkg/tlperl/lib/URI/file/Win32.pm +++ b/Master/tlpkg/tlperl/lib/URI/file/Win32.pm @@ -1,9 +1,10 @@ package URI::file::Win32; -require URI::file::Base; -@ISA=qw(URI::file::Base); - use strict; +use warnings; + +use parent 'URI::file::Base'; + use URI::Escape qw(uri_unescape); sub _file_extract_authority diff --git a/Master/tlpkg/tlperl/lib/URI/ftp.pm b/Master/tlpkg/tlperl/lib/URI/ftp.pm index 89aeb07cdc9..7a3c8ca79e2 100644 --- a/Master/tlpkg/tlperl/lib/URI/ftp.pm +++ b/Master/tlpkg/tlperl/lib/URI/ftp.pm @@ -1,10 +1,9 @@ package URI::ftp; -require URI::_server; -require URI::_userpass; -@ISA=qw(URI::_server URI::_userpass); - use strict; +use warnings; + +use parent qw(URI::_server URI::_userpass); sub default_port { 21 } diff --git a/Master/tlpkg/tlperl/lib/URI/gopher.pm b/Master/tlpkg/tlperl/lib/URI/gopher.pm index ae6690423bc..1da0b11f7ee 100644 --- a/Master/tlpkg/tlperl/lib/URI/gopher.pm +++ b/Master/tlpkg/tlperl/lib/URI/gopher.pm @@ -1,9 +1,10 @@ package URI::gopher; # <draft-murali-url-gopher>, Dec 4, 1996 -require URI::_server; -@ISA=qw(URI::_server); - use strict; +use warnings; + +use parent 'URI::_server'; + use URI::Escape qw(uri_unescape); # A Gopher URL follows the common internet scheme syntax as defined in @@ -58,7 +59,7 @@ sub gopher_type $gtype; } -*gtype = \&gopher_type; # URI::URL compatibility +sub gtype { goto &gopher_type } # URI::URL compatibility sub selector { shift->_gfield(0, @_) } sub search { shift->_gfield(1, @_) } diff --git a/Master/tlpkg/tlperl/lib/URI/http.pm b/Master/tlpkg/tlperl/lib/URI/http.pm index cb698224060..57eb01b21a0 100644 --- a/Master/tlpkg/tlperl/lib/URI/http.pm +++ b/Master/tlpkg/tlperl/lib/URI/http.pm @@ -1,9 +1,9 @@ package URI::http; -require URI::_server; -@ISA=qw(URI::_server); - use strict; +use warnings; + +use parent 'URI::_server'; sub default_port { 80 } diff --git a/Master/tlpkg/tlperl/lib/URI/https.pm b/Master/tlpkg/tlperl/lib/URI/https.pm index 94f9bb19eb4..0937018797b 100644 --- a/Master/tlpkg/tlperl/lib/URI/https.pm +++ b/Master/tlpkg/tlperl/lib/URI/https.pm @@ -1,6 +1,9 @@ package URI::https; -require URI::http; -@ISA=qw(URI::http); + +use strict; +use warnings; + +use parent 'URI::http'; sub default_port { 443 } diff --git a/Master/tlpkg/tlperl/lib/URI/ldap.pm b/Master/tlpkg/tlperl/lib/URI/ldap.pm index 378a9421440..b2cf9777511 100644 --- a/Master/tlpkg/tlperl/lib/URI/ldap.pm +++ b/Master/tlpkg/tlperl/lib/URI/ldap.pm @@ -5,13 +5,11 @@ package URI::ldap; use strict; +use warnings; -use vars qw(@ISA $VERSION); -$VERSION = "1.12"; +our $VERSION = "1.67"; -require URI::_server; -require URI::_ldap; -@ISA=qw(URI::_ldap URI::_server); +use parent qw(URI::_ldap URI::_server); sub default_port { 389 } diff --git a/Master/tlpkg/tlperl/lib/URI/ldapi.pm b/Master/tlpkg/tlperl/lib/URI/ldapi.pm index d92b13f3a49..d717506f037 100644 --- a/Master/tlpkg/tlperl/lib/URI/ldapi.pm +++ b/Master/tlpkg/tlperl/lib/URI/ldapi.pm @@ -1,12 +1,9 @@ package URI::ldapi; use strict; +use warnings; -use vars qw(@ISA); - -require URI::_generic; -require URI::_ldap; -@ISA=qw(URI::_ldap URI::_generic); +use parent qw(URI::_ldap URI::_generic); require URI::Escape; diff --git a/Master/tlpkg/tlperl/lib/URI/ldaps.pm b/Master/tlpkg/tlperl/lib/URI/ldaps.pm index cbf901b11ca..a43d79d6b0c 100644 --- a/Master/tlpkg/tlperl/lib/URI/ldaps.pm +++ b/Master/tlpkg/tlperl/lib/URI/ldaps.pm @@ -1,6 +1,9 @@ package URI::ldaps; -require URI::ldap; -@ISA=qw(URI::ldap); + +use strict; +use warnings; + +use parent 'URI::ldap'; sub default_port { 636 } diff --git a/Master/tlpkg/tlperl/lib/URI/mailto.pm b/Master/tlpkg/tlperl/lib/URI/mailto.pm index 88761c40333..56bbaf8a132 100644 --- a/Master/tlpkg/tlperl/lib/URI/mailto.pm +++ b/Master/tlpkg/tlperl/lib/URI/mailto.pm @@ -1,10 +1,9 @@ package URI::mailto; # RFC 2368 -require URI; -require URI::_query; -@ISA=qw(URI URI::_query); - use strict; +use warnings; + +use parent qw(URI URI::_query); sub to { diff --git a/Master/tlpkg/tlperl/lib/URI/mms.pm b/Master/tlpkg/tlperl/lib/URI/mms.pm index 2f1015b61d9..3c74a39bb8c 100644 --- a/Master/tlpkg/tlperl/lib/URI/mms.pm +++ b/Master/tlpkg/tlperl/lib/URI/mms.pm @@ -1,7 +1,9 @@ package URI::mms; -require URI::http; -@ISA=qw(URI::http); +use strict; +use warnings; + +use parent 'URI::http'; sub default_port { 1755 } diff --git a/Master/tlpkg/tlperl/lib/URI/news.pm b/Master/tlpkg/tlperl/lib/URI/news.pm index 1ffb419f673..fcecba2c53b 100644 --- a/Master/tlpkg/tlperl/lib/URI/news.pm +++ b/Master/tlpkg/tlperl/lib/URI/news.pm @@ -1,9 +1,10 @@ package URI::news; # draft-gilman-news-url-01 -require URI::_server; -@ISA=qw(URI::_server); - use strict; +use warnings; + +use parent 'URI::_server'; + use URI::Escape qw(uri_unescape); use Carp (); @@ -61,7 +62,7 @@ sub message Carp::croak("Message must contain '\@'") unless $_[0] =~ /\@/; } my $old = $self->_group(@_); - return unless $old =~ /\@/; + return undef unless $old =~ /\@/; return $old; } diff --git a/Master/tlpkg/tlperl/lib/URI/nntp.pm b/Master/tlpkg/tlperl/lib/URI/nntp.pm index af61e036cc7..b4fe5d3470b 100644 --- a/Master/tlpkg/tlperl/lib/URI/nntp.pm +++ b/Master/tlpkg/tlperl/lib/URI/nntp.pm @@ -1,6 +1,8 @@ package URI::nntp; # draft-gilman-news-url-01 -require URI::news; -@ISA=qw(URI::news); +use strict; +use warnings; + +use parent 'URI::news'; 1; diff --git a/Master/tlpkg/tlperl/lib/URI/pop.pm b/Master/tlpkg/tlperl/lib/URI/pop.pm index 50b8d6dd511..daac9acd8eb 100644 --- a/Master/tlpkg/tlperl/lib/URI/pop.pm +++ b/Master/tlpkg/tlperl/lib/URI/pop.pm @@ -1,9 +1,10 @@ package URI::pop; # RFC 2384 -require URI::_server; -@ISA=qw(URI::_server); - use strict; +use warnings; + +use parent 'URI::_server'; + use URI::Escape qw(uri_unescape); sub default_port { 110 } @@ -31,7 +32,7 @@ sub user } } - return unless defined $old; + return undef unless defined $old; $old =~ s/;.*//; return uri_unescape($old); } @@ -59,7 +60,7 @@ sub auth } - return unless defined $old; + return undef unless defined $old; $old =~ s/^[^;]*//; return uri_unescape($1) if $old =~ /;auth=(.*)/i; return; diff --git a/Master/tlpkg/tlperl/lib/URI/rlogin.pm b/Master/tlpkg/tlperl/lib/URI/rlogin.pm index 18bb76272a4..b5664e9408c 100644 --- a/Master/tlpkg/tlperl/lib/URI/rlogin.pm +++ b/Master/tlpkg/tlperl/lib/URI/rlogin.pm @@ -1,6 +1,9 @@ package URI::rlogin; -require URI::_login; -@ISA = qw(URI::_login); + +use strict; +use warnings; + +use parent 'URI::_login'; sub default_port { 513 } diff --git a/Master/tlpkg/tlperl/lib/URI/rsync.pm b/Master/tlpkg/tlperl/lib/URI/rsync.pm index 160d9d0c065..bde19072fc6 100644 --- a/Master/tlpkg/tlperl/lib/URI/rsync.pm +++ b/Master/tlpkg/tlperl/lib/URI/rsync.pm @@ -2,10 +2,10 @@ package URI::rsync; # http://rsync.samba.org/ # rsync://[USER@]HOST[:PORT]/SRC -require URI::_server; -require URI::_userpass; +use strict; +use warnings; -@ISA=qw(URI::_server URI::_userpass); +use parent qw(URI::_server URI::_userpass); sub default_port { 873 } diff --git a/Master/tlpkg/tlperl/lib/URI/rtsp.pm b/Master/tlpkg/tlperl/lib/URI/rtsp.pm index 982ca5ebf1e..6b336f4e5ff 100644 --- a/Master/tlpkg/tlperl/lib/URI/rtsp.pm +++ b/Master/tlpkg/tlperl/lib/URI/rtsp.pm @@ -1,7 +1,9 @@ package URI::rtsp; -require URI::http; -@ISA=qw(URI::http); +use strict; +use warnings; + +use parent 'URI::http'; sub default_port { 554 } diff --git a/Master/tlpkg/tlperl/lib/URI/rtspu.pm b/Master/tlpkg/tlperl/lib/URI/rtspu.pm index dbcf12bb2f4..b37454cb63d 100644 --- a/Master/tlpkg/tlperl/lib/URI/rtspu.pm +++ b/Master/tlpkg/tlperl/lib/URI/rtspu.pm @@ -1,7 +1,9 @@ package URI::rtspu; -require URI::rtsp; -@ISA=qw(URI::rtsp); +use strict; +use warnings; + +use parent 'URI::rtsp'; sub default_port { 554 } diff --git a/Master/tlpkg/tlperl/lib/URI/sip.pm b/Master/tlpkg/tlperl/lib/URI/sip.pm index 97bf8630a3d..cee4ea1b953 100644 --- a/Master/tlpkg/tlperl/lib/URI/sip.pm +++ b/Master/tlpkg/tlperl/lib/URI/sip.pm @@ -7,15 +7,14 @@ package URI::sip; -require URI::_server; -require URI::_userpass; -@ISA=qw(URI::_server URI::_userpass); - use strict; -use vars qw(@ISA $VERSION); +use warnings; + +use parent qw(URI::_server URI::_userpass); + use URI::Escape qw(uri_unescape); -$VERSION = "0.11"; +our $VERSION = "1.67"; sub default_port { 5060 } diff --git a/Master/tlpkg/tlperl/lib/URI/sips.pm b/Master/tlpkg/tlperl/lib/URI/sips.pm index 8d184a3d83b..3048e182893 100644 --- a/Master/tlpkg/tlperl/lib/URI/sips.pm +++ b/Master/tlpkg/tlperl/lib/URI/sips.pm @@ -1,6 +1,9 @@ package URI::sips; -require URI::sip; -@ISA=qw(URI::sip); + +use strict; +use warnings; + +use parent 'URI::sip'; sub default_port { 5061 } diff --git a/Master/tlpkg/tlperl/lib/URI/snews.pm b/Master/tlpkg/tlperl/lib/URI/snews.pm index 4310f8111a4..ccf67b41fc1 100644 --- a/Master/tlpkg/tlperl/lib/URI/snews.pm +++ b/Master/tlpkg/tlperl/lib/URI/snews.pm @@ -1,7 +1,9 @@ package URI::snews; # draft-gilman-news-url-01 -require URI::news; -@ISA=qw(URI::news); +use strict; +use warnings; + +use parent 'URI::news'; sub default_port { 563 } diff --git a/Master/tlpkg/tlperl/lib/URI/ssh.pm b/Master/tlpkg/tlperl/lib/URI/ssh.pm index 1d47e4148f6..122cdcb9828 100644 --- a/Master/tlpkg/tlperl/lib/URI/ssh.pm +++ b/Master/tlpkg/tlperl/lib/URI/ssh.pm @@ -1,6 +1,9 @@ package URI::ssh; -require URI::_login; -@ISA=qw(URI::_login); + +use strict; +use warnings; + +use parent 'URI::_login'; # ssh://[USER@]HOST[:PORT]/SRC diff --git a/Master/tlpkg/tlperl/lib/URI/telnet.pm b/Master/tlpkg/tlperl/lib/URI/telnet.pm index 5f842d35787..8431a95ac7c 100644 --- a/Master/tlpkg/tlperl/lib/URI/telnet.pm +++ b/Master/tlpkg/tlperl/lib/URI/telnet.pm @@ -1,6 +1,9 @@ package URI::telnet; -require URI::_login; -@ISA = qw(URI::_login); + +use strict; +use warnings; + +use parent 'URI::_login'; sub default_port { 23 } diff --git a/Master/tlpkg/tlperl/lib/URI/tn3270.pm b/Master/tlpkg/tlperl/lib/URI/tn3270.pm index dd1e648e713..b0f6dc8bf96 100644 --- a/Master/tlpkg/tlperl/lib/URI/tn3270.pm +++ b/Master/tlpkg/tlperl/lib/URI/tn3270.pm @@ -1,6 +1,9 @@ package URI::tn3270; -require URI::_login; -@ISA = qw(URI::_login); + +use strict; +use warnings; + +use parent 'URI::_login'; sub default_port { 23 } diff --git a/Master/tlpkg/tlperl/lib/URI/urn.pm b/Master/tlpkg/tlperl/lib/URI/urn.pm index 12d40b265bc..4c594f5b5da 100644 --- a/Master/tlpkg/tlperl/lib/URI/urn.pm +++ b/Master/tlpkg/tlperl/lib/URI/urn.pm @@ -1,12 +1,13 @@ package URI::urn; # RFC 2141 -require URI; -@ISA=qw(URI); - use strict; +use warnings; + +use parent 'URI'; + use Carp qw(carp); -use vars qw(%implementor); +my %implementor; sub _init { my $class = shift; diff --git a/Master/tlpkg/tlperl/lib/URI/urn/isbn.pm b/Master/tlpkg/tlperl/lib/URI/urn/isbn.pm index 0da931bfb69..b335044b885 100644 --- a/Master/tlpkg/tlperl/lib/URI/urn/isbn.pm +++ b/Master/tlpkg/tlperl/lib/URI/urn/isbn.pm @@ -1,9 +1,10 @@ package URI::urn::isbn; # RFC 3187 -require URI::urn; -@ISA=qw(URI::urn); - use strict; +use warnings; + +use parent 'URI::urn'; + use Carp qw(carp); BEGIN { diff --git a/Master/tlpkg/tlperl/lib/URI/urn/oid.pm b/Master/tlpkg/tlperl/lib/URI/urn/oid.pm index 301b2bcd834..cfe7248a315 100644 --- a/Master/tlpkg/tlperl/lib/URI/urn/oid.pm +++ b/Master/tlpkg/tlperl/lib/URI/urn/oid.pm @@ -1,9 +1,9 @@ package URI::urn::oid; # RFC 2061 -require URI::urn; -@ISA=qw(URI::urn); - use strict; +use warnings; + +use parent 'URI::urn'; sub oid { my $self = shift; |