fix defintions for some dummy functions...

... which are primarily used as placeholders when intializing.
This commit is contained in:
Rainer Gerhards 2016-06-03 10:24:19 +02:00
parent 8a986092c6
commit 7fd33c26f7
2 changed files with 8 additions and 8 deletions

View File

@ -94,17 +94,17 @@ static struct cnfparamblk pblk =
* if the transactional entry points exist.
*/
static rsRetVal
dummyBeginTransaction(void)
dummyBeginTransaction(void * __attribute__((unused)) dummy)
{
return RS_RET_OK;
}
static rsRetVal
dummyEndTransaction(void)
dummyEndTransaction(void * __attribute__((unused)) dummy)
{
return RS_RET_OK;
}
static rsRetVal
dummyIsCompatibleWithFeature(void)
dummyIsCompatibleWithFeature(syslogFeature __attribute__((unused)) eFeat)
{
return RS_RET_INCOMPATIBLE;
}

View File

@ -83,7 +83,7 @@ wtpGetDbgHdr(wtp_t *pThis)
/* Not implemented dummy function for constructor */
static rsRetVal NotImplementedDummy() { return RS_RET_NOT_IMPLEMENTED; }
static rsRetVal NotImplementedDummy(void) { return RS_RET_NOT_IMPLEMENTED; }
/* Standard-Constructor for the wtp object
*/
BEGINobjConstruct(wtp) /* be sure to specify the object type also in END macro! */
@ -98,10 +98,10 @@ BEGINobjConstruct(wtp) /* be sure to specify the object type also in END macro!
#endif
pthread_attr_setdetachstate(&pThis->attrThrd, PTHREAD_CREATE_DETACHED);
/* set all function pointers to "not implemented" dummy so that we can safely call them */
pThis->pfChkStopWrkr = NotImplementedDummy;
pThis->pfGetDeqBatchSize = NotImplementedDummy;
pThis->pfDoWork = NotImplementedDummy;
pThis->pfObjProcessed = NotImplementedDummy;
pThis->pfChkStopWrkr = (rsRetVal (*)(void*,int))NotImplementedDummy;
pThis->pfGetDeqBatchSize = (rsRetVal (*)(void*,int*))NotImplementedDummy;
pThis->pfDoWork = (rsRetVal (*)(void*,void*))NotImplementedDummy;
pThis->pfObjProcessed = (rsRetVal (*)(void*,wti_t*))NotImplementedDummy;
INIT_ATOMIC_HELPER_MUT(pThis->mutCurNumWrkThrd);
INIT_ATOMIC_HELPER_MUT(pThis->mutWtpState);
ENDobjConstruct(wtp)