rem: return soap->error;
add: p = soap->local_namespaces; if (p) { const char *ns = p[0].out; if (!ns) ns = p[0].ns; if (!strcmp(ns, soap_env1)) { soap->version = 1;  if (p[1].out) SOAP_FREE(p[1].out); if ((p[1].out = (char*)SOAP_MALLOC(sizeof(soap_enc1)))) strcpy(p[1].out, soap_enc1); } else if (!strcmp(ns, soap_env2)) { soap->version = 2;  if (p[1].out) SOAP_FREE(p[1].out); if ((p[1].out = (char*)SOAP_MALLOC(sizeof(soap_enc2)))) strcpy(p[1].out, soap_enc2); } } return SOAP_OK;
context: soap_envelope_begin_in(struct soap *soap){ soap->part = SOAP_IN_ENVELOPE;  if (soap_element_begin_in(soap, "SOAP-ENV:Envelope"))    return soap->error = SOAP_VERSIONMISMATCH;  return soap->error;}