{
int i;
- printf("Backtrace for thread Id (%lu) total threads = %d\n", (unsigned long) pthread_self(), osCp.numSTsks);
+ printf("\nBacktrace for thread Id (%lu) total threads = %d\n", (unsigned long) pthread_self(), osCp.numSTsks);
ysPrntBkTrace();
for(i = 0; i < osCp.numSTsks; i++)
{
Void mtSigUsr2Hndlr()
{
- printf("Backtrace for thread Id (%lu) cause:SIGUSR2(%d)\n",(unsigned long) pthread_self(),SIGUSR2);
+ printf("\nBacktrace for thread Id (%lu) cause:SIGUSR2(%d)\n",(unsigned long) pthread_self(),SIGUSR2);
pthread_mutex_lock(&dumpingLock);
ysPrntBkTrace();
* File: ss_gen.c
*
*/
-#ifdef ANSI
-S16 SInit
-(
-void
-)
-#else
-S16 SInit()
-#endif
+S16 SInit(void)
{
S16 ret;
REG1 S16 i;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-S16 SDeInit
-(
-void
-)
-#else
-S16 SDeInit()
-#endif
+S16 SDeInit(void)
{
/* ss007.301 */
uint16_t regCnt;
}
/* ss001.301: additions */
#ifdef SS_LOGGER_SUPPORT
-#ifdef ANSI
S16 SWrtLogBuf
(
Txt *buf /* buffer */
)
-#else
-S16 SWrtLogBuf(buf)
-Txt *buf; /* buffer */
-#endif
{
S16 bufSz;
/* buffer synchronisation*/
* File: ss_gen.c
*
*/
-#ifdef ANSI
S16 SPrint
(
Txt *buf /* buffer */
)
-#else
-S16 SPrint(buf)
-Txt *buf; /* buffer */
-#endif
{
/* ss001.301: additions */
* File: ss_gen.c
*
*/
-#ifdef ANSI
S16 SError
(
Seq seq, /* sequence */
Reason reason /* reason */
)
-#else
-S16 SError(seq, reason)
-Seq seq; /* sequence */
-Reason reason; /* reason */
-#endif
{
S16 ret;
DateTime dt;
* File: ss_gen.c
*
*/
-#ifdef ANSI
Void SLogError
(
Ent ent, /* Calling layer's entity id */
ErrVal errVal, /* error value */
Txt *errDesc /* description of error */
)
-#else
-Void SLogError(ent, inst, procId, file, line,
- errCls, errCode, errVal, errDesc)
-Ent ent; /* Calling layer's entity id */
-Inst inst; /* Calling layer's instance id */
-ProcId procId; /* Calling layer's processor id */
-Txt *file; /* file name where error occured */
-S32 line; /* line in file where error occured */
-ErrCls errCls; /* error class */
-ErrCode errCode; /* layer unique error code */
-ErrVal errVal; /* error value */
-Txt *errDesc; /* description of error */
-#endif
{
DateTime dt;
Txt errBuf[512];
* File: ss_gen.c
*
*/
-#ifdef ANSI
-ProcId SFndProcId
-(
-void
-)
-#else
-ProcId SFndProcId()
-#endif
+ProcId SFndProcId(void)
{
return (osCp.procId);
* File: ss_gen.c
*
*/
-#ifdef ANSI
-Void SSetProcId
-(
-ProcId procId
-)
-#else
-Void SSetProcId(procId)
-ProcId procId;
-#endif
+Void SSetProcId(ProcId procId)
{
osCp.procId = procId;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-uint16_t SGetProcIdIdx
-(
-ProcId proc
-)
-#else
-uint16_t SGetProcIdIdx(proc)
-ProcId proc;
-#endif
+uint16_t SGetProcIdIdx(ProcId proc)
{
uint16_t i;
uint16_t idx;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-static S16 SInsProcId
-(
-ProcId proc
-)
-#else
-static S16 SInsProcId(proc)
-ProcId proc;
-#endif
+static S16 SInsProcId(ProcId proc)
{
uint16_t i;
uint16_t idx;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-static S16 SRemProcId
-(
-ProcId proc
-)
-#else
-static S16 SRemProcId(proc)
-ProcId proc;
-#endif
+static S16 SRemProcId(ProcId proc)
{
uint16_t i;
uint16_t idx;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-static S16 SLockOsCp
-(
-Void
-)
-#else
-static S16 SLockOsCp(Void)
-#endif
+static S16 SLockOsCp(void)
{
S16 ret;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-static S16 SULockOsCp
-(
-Void
-)
-#else
static S16 SULockOsCp(Void)
-#endif
{
/* unlock the table */
* File: ss_gen.c
*
*/
-#ifdef ANSI
-S16 SAddProcIdLst
-(
-uint16_t numPIds,
-ProcId *pIdLst
-)
-#else
-S16 SAddProcIdLst(numPIds, pIdLst)
-uint16_t numPIds;
-ProcId *pIdLst;
-#endif
+S16 SAddProcIdLst(uint16_t numPIds,ProcId *pIdLst)
{
uint16_t i;
S16 ret;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-S16 SRemProcIdLst
-(
-uint16_t numPIds,
-ProcId *pIdLst
-)
-#else
-S16 SRemProcIdLst(numPIds, pIdLst)
-uint16_t numPIds;
-ProcId *pIdLst;
-#endif
+S16 SRemProcIdLst(uint16_t numPIds,ProcId *pIdLst)
{
uint16_t i;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-S16 SGetProcIdLst
-(
-uint16_t *numPIds,
-ProcId *pIdLst
-)
-#else
-S16 SGetProcIdLst(numPIds, pIdLst)
-uint16_t *numPIds;
-ProcId *pIdLst;
-#endif
+S16 SGetProcIdLst(uint16_t *numPIds,ProcId *pIdLst)
{
uint16_t i;
uint16_t count = 0;
* File: ss_gen.c
*
*/
-#ifdef ANSI
S16 SGetXxCb
(
ProcId proc,
Inst inst,
Void **xxCb
)
-#else
-S16 SGetXxCb(proc, ent, inst, xxCb)
-ProcId proc;
-Ent ent;
-Inst inst;
-Void **xxCb;
-#endif
{
uint16_t procIdIdx;
SsIdx idx;
* File: ss_gen.c
*
*/
-#ifdef ANSI
-S16 SFillEntIds
-(
-Void
-)
-#else
S16 SFillEntIds(Void)
-#endif
{
uint8_t entInfo[26][26] = {
*
*
*/
-#ifdef ANSI
-S16 SGetEntInd
-(
-Ent *entId,
-uint8_t *fileName
-)
-#else
-S16 SGetEntInd(entId, fileName)
-Ent *entId;
-uint8_t *fileName;
-#endif
+S16 SGetEntInd(Ent *entId,uint8_t *fileName)
{
* File: mt_ss.c
*
*/
-#ifdef ANSI
-S16 SLockNew
-(
-SLockInfo *lockId,
-uint8_t lockType
-
-)
-#else
-S16 SLockNew(lockId, lockType)
-SLockInfo *lockId;
-uint8_t lockType;
-#endif
+S16 SLockNew(SLockInfo *lockId,uint8_t lockType)
{
S16 retVal = ROK;
* File: mt_ss.c
*
*/
-#ifdef ANSI
-S16 SInitLockNew
-(
-SLockInfo *lockId,
-uint8_t lockType
-)
-#else
-S16 SInitLockNew(lockId, lockType)
-SLockInfo *lockId;
-uint8_t lockType;
-#endif
+S16 SInitLockNew(SLockInfo *lockId,uint8_t lockType)
{
S16 retVal = ROK;
* File: mt_ss.c
*
*/
-#ifdef ANSI
-S16 SUnlockNew
-(
-SLockInfo *lockId,
-uint8_t lockType
-)
-#else
-S16 SUnlockNew(lockId, lockType)
-SLockInfo *lockId;
-uint8_t lockType;
-#endif
+S16 SUnlockNew(SLockInfo *lockId,uint8_t lockType)
{
S16 retVal = ROK;
* File: mt_ss.c
*
*/
-#ifdef ANSI
-S16 SDestroyLockNew
-(
-SLockInfo *lockId,
-uint8_t lockType
-)
-#else
-S16 SDestroyLockNew(lockId, lockType)
-SLockInfo *lockId;
-uint8_t lockType;
-#endif
+S16 SDestroyLockNew(SLockInfo *lockId,uint8_t lockType)
{
S16 retVal = ROK;
if(newNextFreeIdx == 0 || newNextFreeIdx >= MAX_MEM_ALLOCATIONS)
{
- printf("Something wrong in GetNextFreeIdx newNextIdx = %ld\n",newNextFreeIdx);
+ printf("\nSomething wrong in GetNextFreeIdx newNextIdx = %ld\n",newNextFreeIdx);
}
memAllocInfo->nextFreeIdx = newNextFreeIdx;
CRASH_ENB
#endif
- printf("Freeing wrong ptr stored = %p trying to free %p freeing size (%ld)"
+ printf("\nFreeing wrong ptr stored = %p trying to free %p freeing size (%ld)"
"allocated size(%ld) from %s:%ld\n",
memAllocInfo->allocations[idx].ptr,
ptr,
memAllocInfo->allocations[idx].size,
file,
line);
- printf("Allocation was done from %s:%ld\n",memAllocInfo->allocations[idx].file, memAllocInfo->allocations[idx].lineNo);
- printf("***********************************************************\n");
+ printf("\nAllocation was done from %s:%ld\n",memAllocInfo->allocations[idx].file, memAllocInfo->allocations[idx].lineNo);
+ printf("\n***********************************************************\n");
CRASH_ENB
}
StaticMemLeakFileArr[3] == NULL)
{
int *p = 0;
- printf("Could not open files for Static Mem Leak detection logging :( crashing...\n");
+ printf("\nCould not open files for Static Mem Leak detection logging :( crashing...\n");
*p = 100;
}
* File: mt_ss.c
*
*/
-#ifdef ANSI
-S16 SReInitTmr
-(
-void
-)
-#else
-S16 SReInitTmr()
-#endif
+S16 SReInitTmr(void)
{
uint8_t ret = ROK;
Txt prntBuf[PRNTSZE];