summaryrefslogtreecommitdiffstats
path: root/src/glib-2-DllMain.patch
blob: 4ed2ac5369c5b2b53b432348cecaa5bfe86e2481 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
diff -uNr glib-2.28.8-orig/gio/giomodule.c glib/gio/giomodule.c
--- glib-2.28.8-orig/gio/giomodule.c	2011-01-05 22:44:06.000000000 +0100
+++ glib/gio/giomodule.c	2011-11-23 21:04:43.867004895 +0100
@@ -489,10 +489,8 @@
 
 static HMODULE gio_dll = NULL;
 
-#ifdef DLL_EXPORT
-
 BOOL WINAPI
-DllMain (HINSTANCE hinstDLL,
+gio_DllMain (HINSTANCE hinstDLL,
 	 DWORD     fdwReason,
 	 LPVOID    lpvReserved)
 {
@@ -502,8 +500,6 @@
   return TRUE;
 }
 
-#endif
-
 #undef GIO_MODULE_DIR
 
 /* GIO_MODULE_DIR is used only in code called just once,
diff -uNr glib-2.28.8-orig/glib/gutils.c glib/glib/gutils.c
--- glib-2.28.8-orig/glib/gutils.c	2011-06-06 01:18:49.000000000 +0200
+++ glib/glib/gutils.c	2011-11-23 21:05:07.822988144 +0100
@@ -144,10 +144,8 @@
 
 static HMODULE glib_dll = NULL;
 
-#ifdef DLL_EXPORT
-
 BOOL WINAPI
-DllMain (HINSTANCE hinstDLL,
+glib_DllMain (HINSTANCE hinstDLL,
 	 DWORD     fdwReason,
 	 LPVOID    lpvReserved)
 {
@@ -157,8 +155,6 @@
   return TRUE;
 }
 
-#endif
-
 gchar *
 _glib_get_dll_directory (void)
 {
@@ -166,10 +162,8 @@
   gchar *p;
   wchar_t wc_fn[MAX_PATH];
 
-#ifdef DLL_EXPORT
   if (glib_dll == NULL)
     return NULL;
-#endif
 
   /* This code is different from that in
    * g_win32_get_package_installation_directory_of_module() in that