Jump to content
Sign in to follow this  
Tommi Prami

Long standing SOAP bug, please vote

Recommended Posts

First, it would be nice if you posted at least the title of the report here, and not just a link...

 

Not a great report; it is unclear exactly what issue is pointed out in the report, and "difficult to reproduce" in steps isn't going to help matters. If you are affected, you could improve chances of a fix by adding something helpful in comments.

  • Like 2

Share this post


Link to post

Sorry for my bad English.

Reproducing needs true SOAP server. If in WSDL there is property type Class(TXSDate) it can be null, so when trying to convert it to Date OptToSoapConv fails. Why this happens is that in code TSOAPDomConv.SetObjectPropFromText Date kind is expected to be tkFloat. But some how it's PropType is not TDateTime. So Trying to convert it to Float fails.  How we fixed it years ago was that in code procedure TSOAPDomConv.SetObjectPropFromText(Instance: TObject; PropInfo: PPropInfo; const SoapData: InvString);

 

we make this:

    tkFloat:
      begin
        if PropInfo.PropType^ = TypeInfo(TDateTime) then
        begin
          {Fix begins}
          E := XMLTimeToDateTime(SoapData);
          SetFloatProp(Instance, PropInfo, E);
        end
        else
          try
            E := StrToFloatEx(SoapData);
            SetFloatProp(Instance, PropInfo, E);
          except
            VarClear(V);
            SetVariantProp(Instance,PropInfo, V);
          end;

          {Fix ends}
      end;

 

There was  other places too. This problem was even in Delphi 2007.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×