Commit 11401be9 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

winegstreamer: Actually pin module on initialization.

parent d6fcab82
......@@ -275,17 +275,17 @@ static BOOL CALLBACK init_gstreamer_proc(INIT_ONCE *once, void *param, void **ct
*status = gst_init_check(&argc, &argv, &err);
if (*status)
{
HINSTANCE newhandle;
HINSTANCE handle;
TRACE("Inititialized, version %s. Built with %d.%d.%d.\n", gst_version_string(),
GST_VERSION_MAJOR, GST_VERSION_MINOR, GST_VERSION_MICRO);
/* Unloading glib is a bad idea.. it installs atexit handlers,
* so never unload the dll after loading */
GetModuleHandleExW(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
(LPCWSTR)hInst, &newhandle);
if (!newhandle)
ERR("Could not pin module %p\n", hInst);
GetModuleHandleExW(GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS | GET_MODULE_HANDLE_EX_FLAG_PIN,
(LPCWSTR)hInst, &handle);
if (!handle)
ERR("Failed to pin module %p.\n", hInst);
start_dispatch_thread();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment