Switched remoteobject to use a single connection with ACT

This commit is contained in:
2015-05-12 08:36:38 +02:00
parent 4865902a97
commit 9517a6d14e
2 changed files with 52 additions and 96 deletions

View File

@ -1098,7 +1098,7 @@ int SCPureSockWrite(SConnection * self, char *buffer, int iOut)
return 0;
}
if(self->iProtocolID == 4) { /* act */
if(self->iProtocolID == PROTACT) { /* act */
if (strlen(buffer) + 30 > 1024) {
pPtr = (char *) malloc((strlen(buffer) + 30) * sizeof(char));
memset(pPtr, 0, strlen(buffer) + 20);
@ -1110,7 +1110,7 @@ int SCPureSockWrite(SConnection * self, char *buffer, int iOut)
if(pPtr != pBueffel){
free(pPtr);
}
} else if(self->iProtocolID == 3) {
} else if(self->iProtocolID == PROTJSON) {
myJson = mkJSON_Object(self,buffer,iOut);
if(myJson != NULL){
SCDoSockWrite(self,(char *)json_object_to_json_string(myJson));