Optim Data Privacy Providers  11.7.0
 All Data Structures Files Functions Variables Macros Groups Pages
Example for Terminate()

In the following example, the Service Provider termination takes place.

DP_MYCTRL_DEF *pMyCtrlBlk = NULL; //Service Provider control block
// We need to free the provider control block which we have allocated in Init
// Get the service provider control block from the framework control block
pMyCtrlBlk = (DP_MYCTRL_DEF*)pCtrlBlk->pExt;
if(NULL == pMyCtrlBlk)
{
// There is no my service provider control block in Framework control block
return MY_ERR_MYCTRLBLK_NOT_FOUND;
}
// Free the control block
// We should free all the memory allocated into the control block here
free(pMyCtrlBlk);
pMyCtrlBlk = NULL;
return ODPPSUCCESS;