From 17ba72418f9b95b68a7c7d30461fe40a5be32a1b Mon Sep 17 00:00:00 2001 From: zolliker Date: Fri, 18 Jan 2008 07:26:51 +0000 Subject: [PATCH] - changed logging functionality (CompactCommandLog option) --- protocol.c | 9 +++------ servlog.h | 1 + 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/protocol.c b/protocol.c index a9522ee8..909ac1ca 100644 --- a/protocol.c +++ b/protocol.c @@ -514,8 +514,7 @@ int SCWriteSycamore(SConnection *pCon, char *pBuffer, int iOut) /* write to commandlog if user or manager privilege */ if(SCGetRights(pCon) <= usUser) { - sprintf(pBueffel,"To sock %d :",iRet); - WriteToCommandLog(pBueffel,pBuffer); + WriteToCommandLogId(NULL,iRet,pBuffer); } /* put it into the interpreter if present */ @@ -713,15 +712,13 @@ int SCWriteJSON_String(SConnection *pCon, char *pBuffer, int iOut) { if(pCon->iMacro != 1) { - sprintf(pBueffel,"To sock %d :",iRet); - WriteToCommandLog(pBueffel,pBuffer); + WriteToCommandLogId(NULL,iRet,pBuffer); } else { if(iOut == eError || iOut == eWarning) { - sprintf(pBueffel,"To sock %d :",iRet); - WriteToCommandLog(pBueffel,pBuffer); + WriteToCommandLogId(NULL,iRet,pBuffer); } } } diff --git a/servlog.h b/servlog.h index dfb3cbb7..6d88bbbf 100644 --- a/servlog.h +++ b/servlog.h @@ -16,6 +16,7 @@ #define SICSLOG #include "Scommon.h" void SICSLogWrite(char *ptext, OutCode eOut ); + void SICSLogEnable(int flag); int KillCapture(SConnection *pCon); int LogCapture(SConnection *pCon, SicsInterp *pInter, void *pData,