Skip to content

liteav FreeLibrary异常 #16

@wcctml

Description

@wcctml

我的环境是 Visual Studio 2022, 工具集是Visual Studio 2017 - Windows XP (v141_xp)

liteav 11.1.0.4523 ::FreeLibrary(m_hModule); 报异常,如图

`
typedef ITRTCCloud* (__cdecl* GetTRTCShareInstance)();
typedef void(__cdecl* DestroyTRTCShareInstance)();

HMODULE m_hModule(nullptr);
GetTRTCShareInstance getTRTCShareInstance(nullptr);
DestroyTRTCShareInstance destroyTRTCShareInstance(nullptr);
ITRTCCloud* m_pCloud(nullptr);
std::wstring wstrDLLPath = _T("liteav.dll");
m_hModule = ::LoadLibraryEx(wstrDLLPath.c_str(), NULL, LOAD_WITH_ALTERED_SEARCH_PATH);
if (m_hModule)
{
    getTRTCShareInstance = (GetTRTCShareInstance)::GetProcAddress(m_hModule, "getTRTCShareInstance");
    destroyTRTCShareInstance = (DestroyTRTCShareInstance)::GetProcAddress(m_hModule, "destroyTRTCShareInstance");
    m_pCloud = getTRTCShareInstance();
    if (m_pCloud)
    {
        std::string strVersion = m_pCloud->getSDKVersion();
    }
}
if (getTRTCShareInstance || m_pCloud)
{
    destroyTRTCShareInstance();
    m_pCloud = nullptr;
    getTRTCShareInstance = nullptr;
    destroyTRTCShareInstance = nullptr;
}
if (m_hModule)
{
    ::FreeLibrary(m_hModule);
}

`

image

日志文件
LiteAV_C_20231023-24100.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions