openbmc/build/tmp/deploy/sdk/witherspoon-2019-08-08/sysroots/armv6-openbmc-linux-gnueabi/usr/src/debug/rsyslog/8.1903.0-r0/rsyslog-8.1903.0/runtime/modules.c
static rsRetVal findModule(uchar* pModName, int iModNameLen, modInfo_t** pMod)
{
    modInfo_t* pModInfo;
    uchar* pModNameCmp;
    DEFiRet;

    pModInfo = GetNxt(NULL);
    while (pModInfo != NULL)
    {
        if (!strncmp((char*)pModName,
                     (char*)(pModNameCmp = modGetName(pModInfo)),
                     iModNameLen) &&
            (!*(pModNameCmp + iModNameLen) ||
             !strcmp((char*)pModNameCmp + iModNameLen, ".so")))
        {
            dbgprintf("Module '%s' found\n", pModName);
            break;
        }
        pModInfo = GetNxt(pModInfo);
    }
    *pMod = pModInfo;
    RETiRet;
}
/* find module with given name in global list */
find module with given name in global list
find module with given name in global list
static rsRetVal findModule(uchar* pModName, int iModNameLen, modInfo_t** pMod)
{
    modInfo_t* pModInfo;
    uchar* pModNameCmp;
    DEFiRet;
    pModInfo = GetNxt(NULL);
    while (pModInfo != NULL)
    {
        if (!strncmp((char*)pModName,
                     (char*)(pModNameCmp = modGetName(pModInfo)),
                     iModNameLen) &&
            (!*(pModNameCmp + iModNameLen) ||
             !strcmp((char*)pModNameCmp + iModNameLen, ".so")))
        {
            dbgprintf("Module '%s' found\n", pModName);
            break;
        }
        pModInfo = GetNxt(pModInfo);
    }
    *pMod = pModInfo;
    RETiRet;
}
static rsRetVal findModule ( uchar * pModName , int iModNameLen , modInfo_t * * pMod ) { modInfo_t * pModInfo ; uchar * pModNameCmp ; DEFiRet ; pModInfo = GetNxt ( NULL ) ; while ( pModInfo != NULL ) { if ( ! strncmp ( ( char * ) pModName , ( char * ) ( pModNameCmp = modGetName ( pModInfo ) ) , iModNameLen ) && ( ! * ( pModNameCmp + iModNameLen ) || ! strcmp ( ( char * ) pModNameCmp + iModNameLen , " " ) ) ) { dbgprintf ( " \n " , pModName ) ; break ; } pModInfo = GetNxt ( pModInfo ) ; } * pMod = pModInfo ; RETiRet ; }
find module with given name in global list
find module with given name in global list