mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-07 03:15:49 +01:00
Don't leak a handle from _g_io_win32_get_module()
This call increments the DLL refcount by default and needs a flag to avoid that.
This commit is contained in:
parent
f701d6c497
commit
03b574ae66
@ -1120,7 +1120,8 @@ void *
|
||||
_g_io_win32_get_module (void)
|
||||
{
|
||||
if (!gio_dll)
|
||||
GetModuleHandleExA (GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS,
|
||||
GetModuleHandleExA (GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS |
|
||||
GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT,
|
||||
(const char *) _g_io_win32_get_module,
|
||||
&gio_dll);
|
||||
return gio_dll;
|
||||
|
Loading…
x
Reference in New Issue
Block a user