我继承了一些对Microsoft的Mappoint wbeservice进行web服务调用的Perl代码,但在最近的一次升级后,它开始失败,出现了一些神秘的问题:
不是/usr/lib/perl5/site_perl/5.8.0/WebService/Mappoint.pm第35行的哈希引用。
没有发布模块的完整代码(毕竟,
WebService::Mappoint
package WebService::Mappoint;
use SOAP::Lite;
use FileHandle;
use fields qw(ini_file remote_object CustomerInfoHeader UserInfoHeader);
use vars qw(%FIELDS);
use vars qw($VERSION);
$VERSION=0.30;
# @drawmap_EU might be incomplete. It might also contain values that should not be here. Please let me know if there is something wrong
my @EU = (qw(
ad al am at az by ba be bg hr ch cy cz de dk ee es fo fr fi gb ge gi gr hu is ie it lv lt lu mt nl no pl pt ro sk si se tr ua uk yu
));
my %EU;
my %NA = (us=>1, ca=>1, mx=>1);
use strict;
my $ini_files = {};
my ( $user, $password );
my $default_ini_path;
BEGIN {
$default_ini_path = $^O =~ m/windows/i ? 'c:\mappoint.ini' : '/etc/mappoint.ini';
}
##############################################################################
sub new {
my ( $class, $proxy_url, $inifile_path ) = @_;
no strict 'refs';
my $self = bless [\%{"${class}::FIELDS"}], $class;
虽然我可以通过足够多的Perl进行筛选,但我还是有点困惑,为什么这会导致问题,尽管我认为您只能支持哈希,而这似乎是一个匿名数组?