Commit 069b8ae0 authored by Keith Sklower's avatar Keith Sklower
Browse files

After DETER was recently upgraded to FreeBSD8.2 (with corresponding

ports) we noticed that there was an incompatible change in
p5-RPC-XML-0.65 (from 7.2) and -0.76 (from 8.2).

Formerly, RPC::XML::Parser() was OK with parsing only suitably
encoded arguments rather than entire MethodRequest or MethodResponse;
now it throws an error.

We've tested the following (2 + 1) line patches on FreeBSD7.2 and
know them to be backwards compatibile there, and highly suspect it will
be OK for 6.3, although we don't have the means of generating a 6.3
e-in-e anymore.
parent 02769b85
......@@ -185,7 +185,7 @@ my $goo = $parser->parse(*XMLDOC);
if (! ref($goo)) {
fatal("$xmldoc could not be parsed!");
my $opargs = $goo->value();
my $opargs = (@{$goo->args()}[0])->value();
if (! (exists($opargs->{'op'}) && exists($opargs->{'args'}))) {
fatal("missing arguments in xmlgoo");
......@@ -74,7 +74,8 @@ sub commonTail($$)
# over again.
my $args = {"op" => $op, "args" => $arg};
my ($obj) = RPC::XML::smart_encode($args);
my $xs = RPC::XML::struct->new($args);
my $obj = RPC::XML::request->new('passthrough', $xs);
my $response = libxmlrpc::CallMethod0("elabinelab", "vlansv3",
{"xmldoc" => $obj->as_string()});
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment