]> git.donarmstrong.com Git - debbugs.git/blob - cgi/soap.cgi
merge changes from archimedes
[debbugs.git] / cgi / soap.cgi
1 #!/usr/bin/perl -wT
2
3 #use SOAP::Transport::HTTP;
4
5 use Debbugs::SOAP::Server;
6
7 # Work around stupid soap bug on line 411
8 if (not exists $ENV{EXPECT}) {
9      $ENV{EXPECT} = '';
10 }
11
12 my $soap = Debbugs::SOAP::Server
13 #my $soap = SOAP::Transport::HTTP::CGI
14     -> dispatch_to('Debbugs::SOAP');
15 #$soap->serializer()->soapversion(1.2);
16 # soapy is stupid, and is using the 1999 schema; override it.
17 *SOAP::XMLSchema1999::Serializer::as_base64Binary = \&SOAP::XMLSchema2001::Serializer::as_base64Binary;
18 *SOAP::Serializer::as_anyURI       = \&SOAP::XMLSchema2001::Serializer::as_string;
19 # to work around the serializer improperly using date/time stuff
20 # (Nothing in Debbugs should be looked at as if it were date/time) we
21 # kill off all of the date/time related bits in the serializer.
22 my $typelookup = $soap->serializer()->{_typelookup};
23 for my $key (keys %{$type_lookup}) {
24      next unless /Month|Day|Year|date|time|duration/;
25      delete $type_lookup->{$key};
26 }
27 $soap->handle;
28