[12062] Cleanup MaNGOS sources

This commit is contained in:
Schmoozerd 2012-07-19 22:03:32 +02:00
parent a4cbed3199
commit aeff8f9d1a
46 changed files with 1982 additions and 1864 deletions

View file

@ -142,7 +142,8 @@ bool ChatHandler::GetDeletedCharacterInfoList(DeletedInfoList& foundList, std::s
info.deleteDate = time_t(fields[3].GetUInt64()); info.deleteDate = time_t(fields[3].GetUInt64());
foundList.push_back(info); foundList.push_back(info);
} while (resultChar->NextRow()); }
while (resultChar->NextRow());
delete resultChar; delete resultChar;
} }

View file

@ -164,7 +164,8 @@ void SOAPCommand::commandFinished(void* soapconnection, bool success)
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
struct Namespace namespaces[] = struct Namespace namespaces[] =
{ { "SOAP-ENV", "http://schemas.xmlsoap.org/soap/envelope/" }, // must be first {
{ "SOAP-ENV", "http://schemas.xmlsoap.org/soap/envelope/" }, // must be first
{ "SOAP-ENC", "http://schemas.xmlsoap.org/soap/encoding/" }, // must be second { "SOAP-ENC", "http://schemas.xmlsoap.org/soap/encoding/" }, // must be second
{ "xsi", "http://www.w3.org/1999/XMLSchema-instance", "http://www.w3.org/*/XMLSchema-instance" }, { "xsi", "http://www.w3.org/1999/XMLSchema-instance", "http://www.w3.org/*/XMLSchema-instance" },
{ "xsd", "http://www.w3.org/1999/XMLSchema", "http://www.w3.org/*/XMLSchema" }, { "xsd", "http://www.w3.org/1999/XMLSchema", "http://www.w3.org/*/XMLSchema" },

View file

@ -229,7 +229,8 @@ int RASocket::handle_input(ACE_HANDLE)
} }
///<li> If the input is '<password>' (and the user already gave his username) ///<li> If the input is '<password>' (and the user already gave his username)
case LG: case LG:
{ //login+pass ok {
//login+pass ok
std::string pw = inputBuffer; std::string pw = inputBuffer;
if (sAccountMgr.CheckPassword(accId, pw)) if (sAccountMgr.CheckPassword(accId, pw))

View file

@ -21,7 +21,8 @@ SOAP_FMAC3 void SOAP_FMAC4 soap_serializeheader(struct soap *soap)
SOAP_FMAC3 int SOAP_FMAC4 soap_putheader(struct soap* soap) SOAP_FMAC3 int SOAP_FMAC4 soap_putheader(struct soap* soap)
{ {
if (soap->header) if (soap->header)
{ soap->part = SOAP_IN_HEADER; {
soap->part = SOAP_IN_HEADER;
if (soap_out_SOAP_ENV__Header(soap, "SOAP-ENV:Header", 0, soap->header, NULL)) if (soap_out_SOAP_ENV__Header(soap, "SOAP-ENV:Header", 0, soap->header, NULL))
return soap->error; return soap->error;
soap->part = SOAP_END_HEADER; soap->part = SOAP_END_HEADER;
@ -40,7 +41,8 @@ SOAP_FMAC3 int SOAP_FMAC4 soap_getheader(struct soap *soap)
SOAP_FMAC3 void SOAP_FMAC4 soap_header(struct soap* soap) SOAP_FMAC3 void SOAP_FMAC4 soap_header(struct soap* soap)
{ {
if (!soap->header) if (!soap->header)
{ soap->header = soap_new_SOAP_ENV__Header(soap, -1); {
soap->header = soap_new_SOAP_ENV__Header(soap, -1);
soap_default_SOAP_ENV__Header(soap, soap->header); soap_default_SOAP_ENV__Header(soap, soap->header);
} }
} }
@ -48,15 +50,18 @@ SOAP_FMAC3 void SOAP_FMAC4 soap_header(struct soap *soap)
SOAP_FMAC3 void SOAP_FMAC4 soap_fault(struct soap* soap) SOAP_FMAC3 void SOAP_FMAC4 soap_fault(struct soap* soap)
{ {
if (!soap->fault) if (!soap->fault)
{ soap->fault = soap_new_SOAP_ENV__Fault(soap, -1); {
soap->fault = soap_new_SOAP_ENV__Fault(soap, -1);
soap_default_SOAP_ENV__Fault(soap, soap->fault); soap_default_SOAP_ENV__Fault(soap, soap->fault);
} }
if (soap->version == 2 && !soap->fault->SOAP_ENV__Code) if (soap->version == 2 && !soap->fault->SOAP_ENV__Code)
{ soap->fault->SOAP_ENV__Code = soap_new_SOAP_ENV__Code(soap, -1); {
soap->fault->SOAP_ENV__Code = soap_new_SOAP_ENV__Code(soap, -1);
soap_default_SOAP_ENV__Code(soap, soap->fault->SOAP_ENV__Code); soap_default_SOAP_ENV__Code(soap, soap->fault->SOAP_ENV__Code);
} }
if (soap->version == 2 && !soap->fault->SOAP_ENV__Reason) if (soap->version == 2 && !soap->fault->SOAP_ENV__Reason)
{ soap->fault->SOAP_ENV__Reason = soap_new_SOAP_ENV__Reason(soap, -1); {
soap->fault->SOAP_ENV__Reason = soap_new_SOAP_ENV__Reason(soap, -1);
soap_default_SOAP_ENV__Reason(soap, soap->fault->SOAP_ENV__Reason); soap_default_SOAP_ENV__Reason(soap, soap->fault->SOAP_ENV__Reason);
} }
} }
@ -92,8 +97,10 @@ SOAP_FMAC3 const char ** SOAP_FMAC4 soap_faultsubcode(struct soap *soap)
{ {
soap_fault(soap); soap_fault(soap);
if (soap->version == 2) if (soap->version == 2)
{ if (!soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode) {
{ soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode = soap_new_SOAP_ENV__Code(soap, -1); if (!soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode)
{
soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode = soap_new_SOAP_ENV__Code(soap, -1);
soap_default_SOAP_ENV__Code(soap, soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode); soap_default_SOAP_ENV__Code(soap, soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode);
} }
return (const char**)&soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode->SOAP_ENV__Value; return (const char**)&soap->fault->SOAP_ENV__Code->SOAP_ENV__Subcode->SOAP_ENV__Value;
@ -113,14 +120,17 @@ SOAP_FMAC3 const char ** SOAP_FMAC4 soap_faultdetail(struct soap *soap)
{ {
soap_fault(soap); soap_fault(soap);
if (soap->version == 1) if (soap->version == 1)
{ if (!soap->fault->detail) {
{ soap->fault->detail = (struct SOAP_ENV__Detail*)soap_malloc(soap, sizeof(struct SOAP_ENV__Detail)); if (!soap->fault->detail)
{
soap->fault->detail = (struct SOAP_ENV__Detail*)soap_malloc(soap, sizeof(struct SOAP_ENV__Detail));
soap_default_SOAP_ENV__Detail(soap, soap->fault->detail); soap_default_SOAP_ENV__Detail(soap, soap->fault->detail);
} }
return (const char**)&soap->fault->detail->__any; return (const char**)&soap->fault->detail->__any;
} }
if (!soap->fault->SOAP_ENV__Detail) if (!soap->fault->SOAP_ENV__Detail)
{ soap->fault->SOAP_ENV__Detail = soap_new_SOAP_ENV__Detail(soap, -1); {
soap->fault->SOAP_ENV__Detail = soap_new_SOAP_ENV__Detail(soap, -1);
soap_default_SOAP_ENV__Detail(soap, soap->fault->SOAP_ENV__Detail); soap_default_SOAP_ENV__Detail(soap, soap->fault->SOAP_ENV__Detail);
} }
return (const char**)&soap->fault->SOAP_ENV__Detail->__any; return (const char**)&soap->fault->SOAP_ENV__Detail->__any;
@ -166,39 +176,47 @@ SOAP_FMAC3 void * SOAP_FMAC4 soap_getelement(struct soap *soap, int *type)
case SOAP_TYPE_PointerTostring: case SOAP_TYPE_PointerTostring:
return soap_in_PointerTostring(soap, NULL, NULL, "xsd:string"); return soap_in_PointerTostring(soap, NULL, NULL, "xsd:string");
case SOAP_TYPE_string: case SOAP_TYPE_string:
{ char **s; {
char** s;
s = soap_in_string(soap, NULL, NULL, "xsd:string"); s = soap_in_string(soap, NULL, NULL, "xsd:string");
return s ? *s : NULL; return s ? *s : NULL;
} }
default: default:
{ const char *t = soap->type; {
const char* t = soap->type;
if (!*t) if (!*t)
t = soap->tag; t = soap->tag;
if (!soap_match_tag(soap, t, "xsd:byte")) if (!soap_match_tag(soap, t, "xsd:byte"))
{ *type = SOAP_TYPE_byte; {
*type = SOAP_TYPE_byte;
return soap_in_byte(soap, NULL, NULL, NULL); return soap_in_byte(soap, NULL, NULL, NULL);
} }
if (!soap_match_tag(soap, t, "xsd:int")) if (!soap_match_tag(soap, t, "xsd:int"))
{ *type = SOAP_TYPE_int; {
*type = SOAP_TYPE_int;
return soap_in_int(soap, NULL, NULL, NULL); return soap_in_int(soap, NULL, NULL, NULL);
} }
if (!soap_match_tag(soap, t, "ns1:executeCommand")) if (!soap_match_tag(soap, t, "ns1:executeCommand"))
{ *type = SOAP_TYPE_ns1__executeCommand; {
*type = SOAP_TYPE_ns1__executeCommand;
return soap_in_ns1__executeCommand(soap, NULL, NULL, NULL); return soap_in_ns1__executeCommand(soap, NULL, NULL, NULL);
} }
if (!soap_match_tag(soap, t, "ns1:executeCommandResponse")) if (!soap_match_tag(soap, t, "ns1:executeCommandResponse"))
{ *type = SOAP_TYPE_ns1__executeCommandResponse; {
*type = SOAP_TYPE_ns1__executeCommandResponse;
return soap_in_ns1__executeCommandResponse(soap, NULL, NULL, NULL); return soap_in_ns1__executeCommandResponse(soap, NULL, NULL, NULL);
} }
if (!soap_match_tag(soap, t, "xsd:string")) if (!soap_match_tag(soap, t, "xsd:string"))
{ char **s; {
char** s;
*type = SOAP_TYPE_string; *type = SOAP_TYPE_string;
s = soap_in_string(soap, NULL, NULL, NULL); s = soap_in_string(soap, NULL, NULL, NULL);
return s ? *s : NULL; return s ? *s : NULL;
} }
t = soap->tag; t = soap->tag;
if (!soap_match_tag(soap, t, "xsd:QName")) if (!soap_match_tag(soap, t, "xsd:QName"))
{ char **s; {
char** s;
*type = SOAP_TYPE__QName; *type = SOAP_TYPE__QName;
s = soap_in__QName(soap, NULL, NULL, NULL); s = soap_in__QName(soap, NULL, NULL, NULL);
return s ? *s : NULL; return s ? *s : NULL;
@ -217,23 +235,27 @@ SOAP_FMAC3 void * SOAP_FMAC4 soap_getelement(struct soap *soap, int *type)
SOAP_FMAC3 int SOAP_FMAC4 soap_ignore_element(struct soap* soap) SOAP_FMAC3 int SOAP_FMAC4 soap_ignore_element(struct soap* soap)
{ {
if (!soap_peek_element(soap)) if (!soap_peek_element(soap))
{ int t; {
int t;
DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Unexpected element '%s' in input (level=%u, %d)\n", soap->tag, soap->level, soap->body)); DBGLOG(TEST, SOAP_MESSAGE(fdebug, "Unexpected element '%s' in input (level=%u, %d)\n", soap->tag, soap->level, soap->body));
if (soap->mustUnderstand && !soap->other) if (soap->mustUnderstand && !soap->other)
return soap->error = SOAP_MUSTUNDERSTAND; return soap->error = SOAP_MUSTUNDERSTAND;
if (((soap->mode & SOAP_XML_STRICT) && soap->part != SOAP_IN_HEADER) || !soap_match_tag(soap, soap->tag, "SOAP-ENV:")) if (((soap->mode & SOAP_XML_STRICT) && soap->part != SOAP_IN_HEADER) || !soap_match_tag(soap, soap->tag, "SOAP-ENV:"))
{ DBGLOG(TEST, SOAP_MESSAGE(fdebug, "REJECTING element '%s'\n", soap->tag)); {
DBGLOG(TEST, SOAP_MESSAGE(fdebug, "REJECTING element '%s'\n", soap->tag));
return soap->error = SOAP_TAG_MISMATCH; return soap->error = SOAP_TAG_MISMATCH;
} }
if (!*soap->id || !soap_getelement(soap, &t)) if (!*soap->id || !soap_getelement(soap, &t))
{ soap->peeked = 0; {
soap->peeked = 0;
if (soap->fignore) if (soap->fignore)
soap->error = soap->fignore(soap, soap->tag); soap->error = soap->fignore(soap, soap->tag);
else else
soap->error = SOAP_OK; soap->error = SOAP_OK;
DBGLOG(TEST, if (!soap->error) SOAP_MESSAGE(fdebug, "IGNORING element '%s'\n", soap->tag)); DBGLOG(TEST, if (!soap->error) SOAP_MESSAGE(fdebug, "IGNORING element '%s'\n", soap->tag));
if (!soap->error && soap->body) if (!soap->error && soap->body)
{ soap->level++; {
soap->level++;
while (!soap_ignore_element(soap)) while (!soap_ignore_element(soap))
; ;
if (soap->error == SOAP_NO_TAG) if (soap->error == SOAP_NO_TAG)
@ -357,7 +379,8 @@ SOAP_FMAC3 void * SOAP_FMAC4 soap_instantiate(struct soap *soap, int t, const ch
} }
SOAP_FMAC3 int SOAP_FMAC4 soap_fdelete(struct soap_clist* p) SOAP_FMAC3 int SOAP_FMAC4 soap_fdelete(struct soap_clist* p)
{ switch (p->type) {
switch (p->type)
{ {
case SOAP_TYPE_ns1__executeCommandResponse: case SOAP_TYPE_ns1__executeCommandResponse:
if (p->size < 0) if (p->size < 0)
@ -407,11 +430,13 @@ SOAP_FMAC3 int SOAP_FMAC4 soap_fdelete(struct soap_clist *p)
} }
SOAP_FMAC3 void* SOAP_FMAC4 soap_class_id_enter(struct soap* soap, const char* id, void* p, int t, size_t n, const char* type, const char* arrayType) SOAP_FMAC3 void* SOAP_FMAC4 soap_class_id_enter(struct soap* soap, const char* id, void* p, int t, size_t n, const char* type, const char* arrayType)
{ return soap_id_enter(soap, id, p, t, n, 0, type, arrayType, soap_instantiate); {
return soap_id_enter(soap, id, p, t, n, 0, type, arrayType, soap_instantiate);
} }
SOAP_FMAC3 void SOAP_FMAC4 soap_default_byte(struct soap* soap, char* a) SOAP_FMAC3 void SOAP_FMAC4 soap_default_byte(struct soap* soap, char* a)
{ (void)soap; /* appease -Wall -Werror */ {
(void)soap; /* appease -Wall -Werror */
#ifdef SOAP_DEFAULT_byte #ifdef SOAP_DEFAULT_byte
*a = SOAP_DEFAULT_byte; *a = SOAP_DEFAULT_byte;
#else #else
@ -446,7 +471,8 @@ SOAP_FMAC3 char * SOAP_FMAC4 soap_in_byte(struct soap *soap, const char *tag, ch
} }
SOAP_FMAC3 void SOAP_FMAC4 soap_default_int(struct soap* soap, int* a) SOAP_FMAC3 void SOAP_FMAC4 soap_default_int(struct soap* soap, int* a)
{ (void)soap; /* appease -Wall -Werror */ {
(void)soap; /* appease -Wall -Werror */
#ifdef SOAP_DEFAULT_int #ifdef SOAP_DEFAULT_int
*a = SOAP_DEFAULT_int; *a = SOAP_DEFAULT_int;
#else #else
@ -564,50 +590,60 @@ SOAP_FMAC3 struct SOAP_ENV__Fault * SOAP_FMAC4 soap_in_SOAP_ENV__Fault(struct so
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap_flag_faultcode && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_faultcode && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in__QName(soap, "faultcode", &a->faultcode, "")) if (soap_in__QName(soap, "faultcode", &a->faultcode, ""))
{ soap_flag_faultcode--; {
soap_flag_faultcode--;
continue; continue;
} }
if (soap_flag_faultstring && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_faultstring && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in_string(soap, "faultstring", &a->faultstring, "xsd:string")) if (soap_in_string(soap, "faultstring", &a->faultstring, "xsd:string"))
{ soap_flag_faultstring--; {
soap_flag_faultstring--;
continue; continue;
} }
if (soap_flag_faultactor && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_faultactor && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in_string(soap, "faultactor", &a->faultactor, "xsd:string")) if (soap_in_string(soap, "faultactor", &a->faultactor, "xsd:string"))
{ soap_flag_faultactor--; {
soap_flag_faultactor--;
continue; continue;
} }
if (soap_flag_detail && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_detail && soap->error == SOAP_TAG_MISMATCH)
if (soap_in_PointerToSOAP_ENV__Detail(soap, "detail", &a->detail, "")) if (soap_in_PointerToSOAP_ENV__Detail(soap, "detail", &a->detail, ""))
{ soap_flag_detail--; {
soap_flag_detail--;
continue; continue;
} }
if (soap_flag_SOAP_ENV__Code && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_SOAP_ENV__Code && soap->error == SOAP_TAG_MISMATCH)
if (soap_in_PointerToSOAP_ENV__Code(soap, "SOAP-ENV:Code", &a->SOAP_ENV__Code, "")) if (soap_in_PointerToSOAP_ENV__Code(soap, "SOAP-ENV:Code", &a->SOAP_ENV__Code, ""))
{ soap_flag_SOAP_ENV__Code--; {
soap_flag_SOAP_ENV__Code--;
continue; continue;
} }
if (soap_flag_SOAP_ENV__Reason && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_SOAP_ENV__Reason && soap->error == SOAP_TAG_MISMATCH)
if (soap_in_PointerToSOAP_ENV__Reason(soap, "SOAP-ENV:Reason", &a->SOAP_ENV__Reason, "")) if (soap_in_PointerToSOAP_ENV__Reason(soap, "SOAP-ENV:Reason", &a->SOAP_ENV__Reason, ""))
{ soap_flag_SOAP_ENV__Reason--; {
soap_flag_SOAP_ENV__Reason--;
continue; continue;
} }
if (soap_flag_SOAP_ENV__Node && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_SOAP_ENV__Node && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in_string(soap, "SOAP-ENV:Node", &a->SOAP_ENV__Node, "xsd:string")) if (soap_in_string(soap, "SOAP-ENV:Node", &a->SOAP_ENV__Node, "xsd:string"))
{ soap_flag_SOAP_ENV__Node--; {
soap_flag_SOAP_ENV__Node--;
continue; continue;
} }
if (soap_flag_SOAP_ENV__Role && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_SOAP_ENV__Role && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in_string(soap, "SOAP-ENV:Role", &a->SOAP_ENV__Role, "xsd:string")) if (soap_in_string(soap, "SOAP-ENV:Role", &a->SOAP_ENV__Role, "xsd:string"))
{ soap_flag_SOAP_ENV__Role--; {
soap_flag_SOAP_ENV__Role--;
continue; continue;
} }
if (soap_flag_SOAP_ENV__Detail && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_SOAP_ENV__Detail && soap->error == SOAP_TAG_MISMATCH)
if (soap_in_PointerToSOAP_ENV__Detail(soap, "SOAP-ENV:Detail", &a->SOAP_ENV__Detail, "")) if (soap_in_PointerToSOAP_ENV__Detail(soap, "SOAP-ENV:Detail", &a->SOAP_ENV__Detail, ""))
{ soap_flag_SOAP_ENV__Detail--; {
soap_flag_SOAP_ENV__Detail--;
continue; continue;
} }
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
@ -621,7 +657,8 @@ SOAP_FMAC3 struct SOAP_ENV__Fault * SOAP_FMAC4 soap_in_SOAP_ENV__Fault(struct so
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Fault *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Fault, 0, sizeof(struct SOAP_ENV__Fault), 0, NULL); {
a = (struct SOAP_ENV__Fault*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Fault, 0, sizeof(struct SOAP_ENV__Fault), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -629,11 +666,13 @@ SOAP_FMAC3 struct SOAP_ENV__Fault * SOAP_FMAC4 soap_in_SOAP_ENV__Fault(struct so
} }
SOAP_FMAC5 struct SOAP_ENV__Fault* SOAP_FMAC6 soap_new_SOAP_ENV__Fault(struct soap* soap, int n) SOAP_FMAC5 struct SOAP_ENV__Fault* SOAP_FMAC6 soap_new_SOAP_ENV__Fault(struct soap* soap, int n)
{ return soap_instantiate_SOAP_ENV__Fault(soap, n, NULL, NULL, NULL); {
return soap_instantiate_SOAP_ENV__Fault(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Fault(struct soap* soap, struct SOAP_ENV__Fault* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Fault(struct soap* soap, struct SOAP_ENV__Fault* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct SOAP_ENV__Fault* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Fault(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct SOAP_ENV__Fault* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Fault(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -643,14 +682,17 @@ SOAP_FMAC3 struct SOAP_ENV__Fault * SOAP_FMAC4 soap_instantiate_SOAP_ENV__Fault(
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct SOAP_ENV__Fault; {
cp->ptr = (void*)new struct SOAP_ENV__Fault;
if (size) if (size)
*size = sizeof(struct SOAP_ENV__Fault); *size = sizeof(struct SOAP_ENV__Fault);
} }
else else
{ cp->ptr = (void*)new struct SOAP_ENV__Fault[n]; {
cp->ptr = (void*)new struct SOAP_ENV__Fault[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -718,10 +760,12 @@ SOAP_FMAC3 struct SOAP_ENV__Reason * SOAP_FMAC4 soap_in_SOAP_ENV__Reason(struct
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap_flag_SOAP_ENV__Text && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_SOAP_ENV__Text && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in_string(soap, "SOAP-ENV:Text", &a->SOAP_ENV__Text, "xsd:string")) if (soap_in_string(soap, "SOAP-ENV:Text", &a->SOAP_ENV__Text, "xsd:string"))
{ soap_flag_SOAP_ENV__Text--; {
soap_flag_SOAP_ENV__Text--;
continue; continue;
} }
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
@ -735,7 +779,8 @@ SOAP_FMAC3 struct SOAP_ENV__Reason * SOAP_FMAC4 soap_in_SOAP_ENV__Reason(struct
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Reason *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Reason, 0, sizeof(struct SOAP_ENV__Reason), 0, NULL); {
a = (struct SOAP_ENV__Reason*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Reason, 0, sizeof(struct SOAP_ENV__Reason), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -743,11 +788,13 @@ SOAP_FMAC3 struct SOAP_ENV__Reason * SOAP_FMAC4 soap_in_SOAP_ENV__Reason(struct
} }
SOAP_FMAC5 struct SOAP_ENV__Reason* SOAP_FMAC6 soap_new_SOAP_ENV__Reason(struct soap* soap, int n) SOAP_FMAC5 struct SOAP_ENV__Reason* SOAP_FMAC6 soap_new_SOAP_ENV__Reason(struct soap* soap, int n)
{ return soap_instantiate_SOAP_ENV__Reason(soap, n, NULL, NULL, NULL); {
return soap_instantiate_SOAP_ENV__Reason(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Reason(struct soap* soap, struct SOAP_ENV__Reason* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Reason(struct soap* soap, struct SOAP_ENV__Reason* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct SOAP_ENV__Reason* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Reason(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct SOAP_ENV__Reason* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Reason(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -757,14 +804,17 @@ SOAP_FMAC3 struct SOAP_ENV__Reason * SOAP_FMAC4 soap_instantiate_SOAP_ENV__Reaso
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct SOAP_ENV__Reason; {
cp->ptr = (void*)new struct SOAP_ENV__Reason;
if (size) if (size)
*size = sizeof(struct SOAP_ENV__Reason); *size = sizeof(struct SOAP_ENV__Reason);
} }
else else
{ cp->ptr = (void*)new struct SOAP_ENV__Reason[n]; {
cp->ptr = (void*)new struct SOAP_ENV__Reason[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -835,15 +885,18 @@ SOAP_FMAC3 struct SOAP_ENV__Detail * SOAP_FMAC4 soap_in_SOAP_ENV__Detail(struct
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap_flag_fault && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_fault && soap->error == SOAP_TAG_MISMATCH)
if ((a->fault = soap_getelement(soap, &a->__type))) if ((a->fault = soap_getelement(soap, &a->__type)))
{ soap_flag_fault = 0; {
soap_flag_fault = 0;
continue; continue;
} }
if (soap_flag___any && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag___any && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_inliteral(soap, "-any", &a->__any)) if (soap_inliteral(soap, "-any", &a->__any))
{ soap_flag___any--; {
soap_flag___any--;
continue; continue;
} }
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
@ -857,7 +910,8 @@ SOAP_FMAC3 struct SOAP_ENV__Detail * SOAP_FMAC4 soap_in_SOAP_ENV__Detail(struct
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Detail *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Detail, 0, sizeof(struct SOAP_ENV__Detail), 0, NULL); {
a = (struct SOAP_ENV__Detail*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Detail, 0, sizeof(struct SOAP_ENV__Detail), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -865,11 +919,13 @@ SOAP_FMAC3 struct SOAP_ENV__Detail * SOAP_FMAC4 soap_in_SOAP_ENV__Detail(struct
} }
SOAP_FMAC5 struct SOAP_ENV__Detail* SOAP_FMAC6 soap_new_SOAP_ENV__Detail(struct soap* soap, int n) SOAP_FMAC5 struct SOAP_ENV__Detail* SOAP_FMAC6 soap_new_SOAP_ENV__Detail(struct soap* soap, int n)
{ return soap_instantiate_SOAP_ENV__Detail(soap, n, NULL, NULL, NULL); {
return soap_instantiate_SOAP_ENV__Detail(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Detail(struct soap* soap, struct SOAP_ENV__Detail* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Detail(struct soap* soap, struct SOAP_ENV__Detail* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct SOAP_ENV__Detail* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Detail(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct SOAP_ENV__Detail* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Detail(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -879,14 +935,17 @@ SOAP_FMAC3 struct SOAP_ENV__Detail * SOAP_FMAC4 soap_instantiate_SOAP_ENV__Detai
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct SOAP_ENV__Detail; {
cp->ptr = (void*)new struct SOAP_ENV__Detail;
if (size) if (size)
*size = sizeof(struct SOAP_ENV__Detail); *size = sizeof(struct SOAP_ENV__Detail);
} }
else else
{ cp->ptr = (void*)new struct SOAP_ENV__Detail[n]; {
cp->ptr = (void*)new struct SOAP_ENV__Detail[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -959,15 +1018,18 @@ SOAP_FMAC3 struct SOAP_ENV__Code * SOAP_FMAC4 soap_in_SOAP_ENV__Code(struct soap
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap_flag_SOAP_ENV__Value && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_SOAP_ENV__Value && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in__QName(soap, "SOAP-ENV:Value", &a->SOAP_ENV__Value, "")) if (soap_in__QName(soap, "SOAP-ENV:Value", &a->SOAP_ENV__Value, ""))
{ soap_flag_SOAP_ENV__Value--; {
soap_flag_SOAP_ENV__Value--;
continue; continue;
} }
if (soap_flag_SOAP_ENV__Subcode && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_SOAP_ENV__Subcode && soap->error == SOAP_TAG_MISMATCH)
if (soap_in_PointerToSOAP_ENV__Code(soap, "SOAP-ENV:Subcode", &a->SOAP_ENV__Subcode, "")) if (soap_in_PointerToSOAP_ENV__Code(soap, "SOAP-ENV:Subcode", &a->SOAP_ENV__Subcode, ""))
{ soap_flag_SOAP_ENV__Subcode--; {
soap_flag_SOAP_ENV__Subcode--;
continue; continue;
} }
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
@ -981,7 +1043,8 @@ SOAP_FMAC3 struct SOAP_ENV__Code * SOAP_FMAC4 soap_in_SOAP_ENV__Code(struct soap
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Code *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Code, 0, sizeof(struct SOAP_ENV__Code), 0, NULL); {
a = (struct SOAP_ENV__Code*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Code, 0, sizeof(struct SOAP_ENV__Code), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -989,11 +1052,13 @@ SOAP_FMAC3 struct SOAP_ENV__Code * SOAP_FMAC4 soap_in_SOAP_ENV__Code(struct soap
} }
SOAP_FMAC5 struct SOAP_ENV__Code* SOAP_FMAC6 soap_new_SOAP_ENV__Code(struct soap* soap, int n) SOAP_FMAC5 struct SOAP_ENV__Code* SOAP_FMAC6 soap_new_SOAP_ENV__Code(struct soap* soap, int n)
{ return soap_instantiate_SOAP_ENV__Code(soap, n, NULL, NULL, NULL); {
return soap_instantiate_SOAP_ENV__Code(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Code(struct soap* soap, struct SOAP_ENV__Code* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Code(struct soap* soap, struct SOAP_ENV__Code* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct SOAP_ENV__Code* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Code(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct SOAP_ENV__Code* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Code(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -1003,14 +1068,17 @@ SOAP_FMAC3 struct SOAP_ENV__Code * SOAP_FMAC4 soap_instantiate_SOAP_ENV__Code(st
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct SOAP_ENV__Code; {
cp->ptr = (void*)new struct SOAP_ENV__Code;
if (size) if (size)
*size = sizeof(struct SOAP_ENV__Code); *size = sizeof(struct SOAP_ENV__Code);
} }
else else
{ cp->ptr = (void*)new struct SOAP_ENV__Code[n]; {
cp->ptr = (void*)new struct SOAP_ENV__Code[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -1073,7 +1141,8 @@ SOAP_FMAC3 struct SOAP_ENV__Header * SOAP_FMAC4 soap_in_SOAP_ENV__Header(struct
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
soap->error = soap_ignore_element(soap); soap->error = soap_ignore_element(soap);
if (soap->error == SOAP_NO_TAG) if (soap->error == SOAP_NO_TAG)
@ -1085,7 +1154,8 @@ SOAP_FMAC3 struct SOAP_ENV__Header * SOAP_FMAC4 soap_in_SOAP_ENV__Header(struct
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Header *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Header, 0, sizeof(struct SOAP_ENV__Header), 0, NULL); {
a = (struct SOAP_ENV__Header*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_SOAP_ENV__Header, 0, sizeof(struct SOAP_ENV__Header), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1093,11 +1163,13 @@ SOAP_FMAC3 struct SOAP_ENV__Header * SOAP_FMAC4 soap_in_SOAP_ENV__Header(struct
} }
SOAP_FMAC5 struct SOAP_ENV__Header* SOAP_FMAC6 soap_new_SOAP_ENV__Header(struct soap* soap, int n) SOAP_FMAC5 struct SOAP_ENV__Header* SOAP_FMAC6 soap_new_SOAP_ENV__Header(struct soap* soap, int n)
{ return soap_instantiate_SOAP_ENV__Header(soap, n, NULL, NULL, NULL); {
return soap_instantiate_SOAP_ENV__Header(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Header(struct soap* soap, struct SOAP_ENV__Header* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_SOAP_ENV__Header(struct soap* soap, struct SOAP_ENV__Header* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct SOAP_ENV__Header* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Header(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct SOAP_ENV__Header* SOAP_FMAC4 soap_instantiate_SOAP_ENV__Header(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -1107,14 +1179,17 @@ SOAP_FMAC3 struct SOAP_ENV__Header * SOAP_FMAC4 soap_instantiate_SOAP_ENV__Heade
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct SOAP_ENV__Header; {
cp->ptr = (void*)new struct SOAP_ENV__Header;
if (size) if (size)
*size = sizeof(struct SOAP_ENV__Header); *size = sizeof(struct SOAP_ENV__Header);
} }
else else
{ cp->ptr = (void*)new struct SOAP_ENV__Header[n]; {
cp->ptr = (void*)new struct SOAP_ENV__Header[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -1180,10 +1255,12 @@ SOAP_FMAC3 struct ns1__executeCommand * SOAP_FMAC4 soap_in_ns1__executeCommand(s
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap_flag_command && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG)) if (soap_flag_command && (soap->error == SOAP_TAG_MISMATCH || soap->error == SOAP_NO_TAG))
if (soap_in_string(soap, "command", &a->command, "xsd:string")) if (soap_in_string(soap, "command", &a->command, "xsd:string"))
{ soap_flag_command--; {
soap_flag_command--;
continue; continue;
} }
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
@ -1197,7 +1274,8 @@ SOAP_FMAC3 struct ns1__executeCommand * SOAP_FMAC4 soap_in_ns1__executeCommand(s
return NULL; return NULL;
} }
else else
{ a = (struct ns1__executeCommand *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_ns1__executeCommand, 0, sizeof(struct ns1__executeCommand), 0, NULL); {
a = (struct ns1__executeCommand*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_ns1__executeCommand, 0, sizeof(struct ns1__executeCommand), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1205,11 +1283,13 @@ SOAP_FMAC3 struct ns1__executeCommand * SOAP_FMAC4 soap_in_ns1__executeCommand(s
} }
SOAP_FMAC5 struct ns1__executeCommand* SOAP_FMAC6 soap_new_ns1__executeCommand(struct soap* soap, int n) SOAP_FMAC5 struct ns1__executeCommand* SOAP_FMAC6 soap_new_ns1__executeCommand(struct soap* soap, int n)
{ return soap_instantiate_ns1__executeCommand(soap, n, NULL, NULL, NULL); {
return soap_instantiate_ns1__executeCommand(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_ns1__executeCommand(struct soap* soap, struct ns1__executeCommand* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_ns1__executeCommand(struct soap* soap, struct ns1__executeCommand* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct ns1__executeCommand* SOAP_FMAC4 soap_instantiate_ns1__executeCommand(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct ns1__executeCommand* SOAP_FMAC4 soap_instantiate_ns1__executeCommand(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -1219,14 +1299,17 @@ SOAP_FMAC3 struct ns1__executeCommand * SOAP_FMAC4 soap_instantiate_ns1__execute
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct ns1__executeCommand; {
cp->ptr = (void*)new struct ns1__executeCommand;
if (size) if (size)
*size = sizeof(struct ns1__executeCommand); *size = sizeof(struct ns1__executeCommand);
} }
else else
{ cp->ptr = (void*)new struct ns1__executeCommand[n]; {
cp->ptr = (void*)new struct ns1__executeCommand[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -1290,10 +1373,12 @@ SOAP_FMAC3 struct ns1__executeCommandResponse * SOAP_FMAC4 soap_in_ns1__executeC
if (soap->body && !*soap->href) if (soap->body && !*soap->href)
{ {
for (;;) for (;;)
{ soap->error = SOAP_TAG_MISMATCH; {
soap->error = SOAP_TAG_MISMATCH;
if (soap_flag_result && soap->error == SOAP_TAG_MISMATCH) if (soap_flag_result && soap->error == SOAP_TAG_MISMATCH)
if (soap_in_PointerTostring(soap, "result", &a->result, "xsd:string")) if (soap_in_PointerTostring(soap, "result", &a->result, "xsd:string"))
{ soap_flag_result--; {
soap_flag_result--;
continue; continue;
} }
if (soap->error == SOAP_TAG_MISMATCH) if (soap->error == SOAP_TAG_MISMATCH)
@ -1307,7 +1392,8 @@ SOAP_FMAC3 struct ns1__executeCommandResponse * SOAP_FMAC4 soap_in_ns1__executeC
return NULL; return NULL;
} }
else else
{ a = (struct ns1__executeCommandResponse *)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_ns1__executeCommandResponse, 0, sizeof(struct ns1__executeCommandResponse), 0, NULL); {
a = (struct ns1__executeCommandResponse*)soap_id_forward(soap, soap->href, (void*)a, 0, SOAP_TYPE_ns1__executeCommandResponse, 0, sizeof(struct ns1__executeCommandResponse), 0, NULL);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1315,11 +1401,13 @@ SOAP_FMAC3 struct ns1__executeCommandResponse * SOAP_FMAC4 soap_in_ns1__executeC
} }
SOAP_FMAC5 struct ns1__executeCommandResponse* SOAP_FMAC6 soap_new_ns1__executeCommandResponse(struct soap* soap, int n) SOAP_FMAC5 struct ns1__executeCommandResponse* SOAP_FMAC6 soap_new_ns1__executeCommandResponse(struct soap* soap, int n)
{ return soap_instantiate_ns1__executeCommandResponse(soap, n, NULL, NULL, NULL); {
return soap_instantiate_ns1__executeCommandResponse(soap, n, NULL, NULL, NULL);
} }
SOAP_FMAC5 void SOAP_FMAC6 soap_delete_ns1__executeCommandResponse(struct soap* soap, struct ns1__executeCommandResponse* p) SOAP_FMAC5 void SOAP_FMAC6 soap_delete_ns1__executeCommandResponse(struct soap* soap, struct ns1__executeCommandResponse* p)
{ soap_delete(soap, p); {
soap_delete(soap, p);
} }
SOAP_FMAC3 struct ns1__executeCommandResponse* SOAP_FMAC4 soap_instantiate_ns1__executeCommandResponse(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size) SOAP_FMAC3 struct ns1__executeCommandResponse* SOAP_FMAC4 soap_instantiate_ns1__executeCommandResponse(struct soap* soap, int n, const char* type, const char* arrayType, size_t* size)
@ -1329,14 +1417,17 @@ SOAP_FMAC3 struct ns1__executeCommandResponse * SOAP_FMAC4 soap_instantiate_ns1_
if (!cp) if (!cp)
return NULL; return NULL;
if (n < 0) if (n < 0)
{ cp->ptr = (void*)new struct ns1__executeCommandResponse; {
cp->ptr = (void*)new struct ns1__executeCommandResponse;
if (size) if (size)
*size = sizeof(struct ns1__executeCommandResponse); *size = sizeof(struct ns1__executeCommandResponse);
} }
else else
{ cp->ptr = (void*)new struct ns1__executeCommandResponse[n]; {
cp->ptr = (void*)new struct ns1__executeCommandResponse[n];
if (!cp->ptr) if (!cp->ptr)
{ soap->error = SOAP_EOM; {
soap->error = SOAP_EOM;
return NULL; return NULL;
} }
if (size) if (size)
@ -1392,12 +1483,14 @@ SOAP_FMAC3 struct SOAP_ENV__Reason ** SOAP_FMAC4 soap_in_PointerToSOAP_ENV__Reas
return NULL; return NULL;
*a = NULL; *a = NULL;
if (!soap->null && *soap->href != '#') if (!soap->null && *soap->href != '#')
{ soap_revert(soap); {
soap_revert(soap);
if (!(*a = soap_in_SOAP_ENV__Reason(soap, tag, *a, type))) if (!(*a = soap_in_SOAP_ENV__Reason(soap, tag, *a, type)))
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Reason **)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_SOAP_ENV__Reason, sizeof(struct SOAP_ENV__Reason), 0); {
a = (struct SOAP_ENV__Reason**)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_SOAP_ENV__Reason, sizeof(struct SOAP_ENV__Reason), 0);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1447,12 +1540,14 @@ SOAP_FMAC3 struct SOAP_ENV__Detail ** SOAP_FMAC4 soap_in_PointerToSOAP_ENV__Deta
return NULL; return NULL;
*a = NULL; *a = NULL;
if (!soap->null && *soap->href != '#') if (!soap->null && *soap->href != '#')
{ soap_revert(soap); {
soap_revert(soap);
if (!(*a = soap_in_SOAP_ENV__Detail(soap, tag, *a, type))) if (!(*a = soap_in_SOAP_ENV__Detail(soap, tag, *a, type)))
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Detail **)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_SOAP_ENV__Detail, sizeof(struct SOAP_ENV__Detail), 0); {
a = (struct SOAP_ENV__Detail**)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_SOAP_ENV__Detail, sizeof(struct SOAP_ENV__Detail), 0);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1502,12 +1597,14 @@ SOAP_FMAC3 struct SOAP_ENV__Code ** SOAP_FMAC4 soap_in_PointerToSOAP_ENV__Code(s
return NULL; return NULL;
*a = NULL; *a = NULL;
if (!soap->null && *soap->href != '#') if (!soap->null && *soap->href != '#')
{ soap_revert(soap); {
soap_revert(soap);
if (!(*a = soap_in_SOAP_ENV__Code(soap, tag, *a, type))) if (!(*a = soap_in_SOAP_ENV__Code(soap, tag, *a, type)))
return NULL; return NULL;
} }
else else
{ a = (struct SOAP_ENV__Code **)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_SOAP_ENV__Code, sizeof(struct SOAP_ENV__Code), 0); {
a = (struct SOAP_ENV__Code**)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_SOAP_ENV__Code, sizeof(struct SOAP_ENV__Code), 0);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1555,12 +1652,14 @@ SOAP_FMAC3 char *** SOAP_FMAC4 soap_in_PointerTostring(struct soap *soap, const
return NULL; return NULL;
*a = NULL; *a = NULL;
if (!soap->null && *soap->href != '#') if (!soap->null && *soap->href != '#')
{ soap_revert(soap); {
soap_revert(soap);
if (!(*a = soap_in_string(soap, tag, *a, type))) if (!(*a = soap_in_string(soap, tag, *a, type)))
return NULL; return NULL;
} }
else else
{ a = (char ***)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_string, sizeof(char *), 1); {
a = (char***)soap_id_lookup(soap, soap->href, (void**)a, SOAP_TYPE_string, sizeof(char*), 1);
if (soap->body && soap_element_end_in(soap, tag)) if (soap->body && soap_element_end_in(soap, tag))
return NULL; return NULL;
} }
@ -1568,11 +1667,13 @@ SOAP_FMAC3 char *** SOAP_FMAC4 soap_in_PointerTostring(struct soap *soap, const
} }
SOAP_FMAC3 void SOAP_FMAC4 soap_default__QName(struct soap* soap, char** a) SOAP_FMAC3 void SOAP_FMAC4 soap_default__QName(struct soap* soap, char** a)
{ soap_default_string(soap, a); {
soap_default_string(soap, a);
} }
SOAP_FMAC3 void SOAP_FMAC4 soap_serialize__QName(struct soap* soap, char* const* a) SOAP_FMAC3 void SOAP_FMAC4 soap_serialize__QName(struct soap* soap, char* const* a)
{ soap_serialize_string(soap, a); {
soap_serialize_string(soap, a);
} }
SOAP_FMAC3 int SOAP_FMAC4 soap_put__QName(struct soap* soap, char* const* a, const char* tag, const char* type) SOAP_FMAC3 int SOAP_FMAC4 soap_put__QName(struct soap* soap, char* const* a, const char* tag, const char* type)
@ -1602,7 +1703,8 @@ SOAP_FMAC3 char * * SOAP_FMAC4 soap_in__QName(struct soap *soap, const char *tag
} }
SOAP_FMAC3 void SOAP_FMAC4 soap_default_string(struct soap* soap, char** a) SOAP_FMAC3 void SOAP_FMAC4 soap_default_string(struct soap* soap, char** a)
{ (void)soap; /* appease -Wall -Werror */ {
(void)soap; /* appease -Wall -Werror */
#ifdef SOAP_DEFAULT_string #ifdef SOAP_DEFAULT_string
*a = SOAP_DEFAULT_string; *a = SOAP_DEFAULT_string;
#else #else

View file

@ -33,7 +33,8 @@ SOAP_FMAC5 int SOAP_FMAC6 soap_serve(struct soap *soap)
#endif #endif
if (soap_begin_recv(soap)) if (soap_begin_recv(soap))
{ if (soap->error < SOAP_STOP) {
if (soap->error < SOAP_STOP)
{ {
#ifdef WITH_FASTCGI #ifdef WITH_FASTCGI
soap_send_fault(soap); soap_send_fault(soap);
@ -62,7 +63,8 @@ SOAP_FMAC5 int SOAP_FMAC6 soap_serve(struct soap *soap)
#ifdef WITH_FASTCGI #ifdef WITH_FASTCGI
soap_destroy(soap); soap_destroy(soap);
soap_end(soap); soap_end(soap);
} while (1); }
while (1);
#else #else
} while (soap->keep_alive); } while (soap->keep_alive);
#endif #endif
@ -80,7 +82,8 @@ SOAP_FMAC5 int SOAP_FMAC6 soap_serve_request(struct soap *soap)
#endif #endif
SOAP_FMAC5 int SOAP_FMAC6 soap_serve_ns1__executeCommand(struct soap* soap) SOAP_FMAC5 int SOAP_FMAC6 soap_serve_ns1__executeCommand(struct soap* soap)
{ struct ns1__executeCommand soap_tmp_ns1__executeCommand; {
struct ns1__executeCommand soap_tmp_ns1__executeCommand;
struct ns1__executeCommandResponse soap_tmp_ns1__executeCommandResponse; struct ns1__executeCommandResponse soap_tmp_ns1__executeCommandResponse;
char* soap_tmp_string; char* soap_tmp_string;
soap_default_ns1__executeCommandResponse(soap, &soap_tmp_ns1__executeCommandResponse); soap_default_ns1__executeCommandResponse(soap, &soap_tmp_ns1__executeCommandResponse);
@ -102,7 +105,8 @@ SOAP_FMAC5 int SOAP_FMAC6 soap_serve_ns1__executeCommand(struct soap *soap)
if (soap_begin_count(soap)) if (soap_begin_count(soap))
return soap->error; return soap->error;
if (soap->mode & SOAP_IO_LENGTH) if (soap->mode & SOAP_IO_LENGTH)
{ if (soap_envelope_begin_out(soap) {
if (soap_envelope_begin_out(soap)
|| soap_putheader(soap) || soap_putheader(soap)
|| soap_body_begin_out(soap) || soap_body_begin_out(soap)
|| soap_put_ns1__executeCommandResponse(soap, &soap_tmp_ns1__executeCommandResponse, "ns1:executeCommandResponse", "") || soap_put_ns1__executeCommandResponse(soap, &soap_tmp_ns1__executeCommandResponse, "ns1:executeCommandResponse", "")

View file

@ -18,7 +18,8 @@
#include "Common.h" #include "Common.h"
char const* localeNames[MAX_LOCALE] = { char const* localeNames[MAX_LOCALE] =
{
"enUS", // also enGB "enUS", // also enGB
"koKR", "koKR",
"frFR", "frFR",

View file

@ -37,7 +37,8 @@ void daemonSignal(int s)
exit(EXIT_SUCCESS); exit(EXIT_SUCCESS);
} }
if (sid) { if (sid)
{
kill(sid, s); kill(sid, s);
} }
@ -57,11 +58,13 @@ void startDaemon(uint32_t timeout)
sid = pid = fork(); sid = pid = fork();
if (pid < 0) { if (pid < 0)
{
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
} }
if (pid > 0) { if (pid > 0)
{
alarm(timeout); alarm(timeout);
pause(); pause();
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
@ -71,11 +74,13 @@ void startDaemon(uint32_t timeout)
sid = setsid(); sid = setsid();
if (sid < 0) { if (sid < 0)
{
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
} }
if ((chdir("/")) < 0) { if ((chdir("/")) < 0)
{
exit(EXIT_FAILURE); exit(EXIT_FAILURE);
} }

View file

@ -423,7 +423,8 @@ std::wstring GetMainPartOfName(std::wstring wname, uint32 declension)
static wchar_t const soft_End[] = { wchar_t(1), wchar_t(0x044C),wchar_t(0x0000)}; static wchar_t const soft_End[] = { wchar_t(1), wchar_t(0x044C),wchar_t(0x0000)};
static wchar_t const j_End[] = { wchar_t(1), wchar_t(0x0439),wchar_t(0x0000)}; static wchar_t const j_End[] = { wchar_t(1), wchar_t(0x0439),wchar_t(0x0000)};
static wchar_t const* const dropEnds[6][8] = { static wchar_t const* const dropEnds[6][8] =
{
{ &a_End[1], &o_End[1], &ya_End[1], &ie_End[1], &soft_End[1], &j_End[1], NULL, NULL }, { &a_End[1], &o_End[1], &ya_End[1], &ie_End[1], &soft_End[1], &j_End[1], NULL, NULL },
{ &a_End[1], &ya_End[1], &yeru_End[1], &i_End[1], NULL, NULL, NULL, NULL }, { &a_End[1], &ya_End[1], &yeru_End[1], &i_End[1], NULL, NULL, NULL, NULL },
{ &ie_End[1], &u_End[1], &yu_End[1], &i_End[1], NULL, NULL, NULL, NULL }, { &ie_End[1], &u_End[1], &yu_End[1], &i_End[1], NULL, NULL, NULL, NULL },

View file

@ -369,7 +369,8 @@ void WheatyExceptionReport::printTracesForAllThreads()
} }
CloseHandle(threadHandle); CloseHandle(threadHandle);
} }
} while( Thread32Next(hThreadSnap, &te32 ) ); }
while (Thread32Next(hThreadSnap, &te32));
// Don't forget to clean up the snapshot object. // Don't forget to clean up the snapshot object.
CloseHandle(hThreadSnap); CloseHandle(hThreadSnap);
@ -772,7 +773,8 @@ unsigned cbBuffer )
if (pSym->Flags & IMAGEHLP_SYMBOL_INFO_REGRELATIVE) if (pSym->Flags & IMAGEHLP_SYMBOL_INFO_REGRELATIVE)
{ {
// if ( pSym->Register == 8 ) // EBP is the value 8 (in DBGHELP 5.1) // if ( pSym->Register == 8 ) // EBP is the value 8 (in DBGHELP 5.1)
{ // This may change!!! {
// This may change!!!
pVariable = sf->AddrFrame.Offset; pVariable = sf->AddrFrame.Offset;
pVariable += (DWORD_PTR)pSym->Address; pVariable += (DWORD_PTR)pSym->Address;
} }

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__ #ifndef __REVISION_NR_H__
#define __REVISION_NR_H__ #define __REVISION_NR_H__
#define REVISION_NR "12061" #define REVISION_NR "12062"
#endif // __REVISION_NR_H__ #endif // __REVISION_NR_H__