Ruben Laguna's blog

Dec 13, 2007 - 1 minute read - Comments - axis2 gsoap Uncategorized with_noio


I’m using an Axis2 Java client to communicate with a gSoap web service. Axis2 rejects the gSoap response so I used wireshark to see what’s gSoap sending back. Now it’s clear what is the problem, gSoap is not sending the “HTTP/1.1 200 OK” as the first line. That’s because I’m using WITH_NOIO, so if your are having the same problem either write yourself the “HTTP/1.1 200 OK” line into the response or change the stdsoap2.c file to send the line anyway. just look for the line

if (soap_valid_socket(soap->master) || soap_valid_socket(soap->socket))
sprintf(soap->tmpbuf, "HTTP/%s %s", soap->http_version, s);

nor soapmaster nor soap>socket would be valid sockets if you are handling the sockets yourself outside gSoap (and if you’re using WITH_NOID that’s probably the case) so that if clause will be always false. you can wrap that if clause with a “#ifndef WITH_NOID” or just comment out the if.

Bringing a cat to Sweden from a EU country Super Screenshot!