[glib] win32 fixes from g_thread_init() deprecation
- From: Ryan Lortie <ryanl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib] win32 fixes from g_thread_init() deprecation
- Date: Tue, 4 Oct 2011 19:45:36 +0000 (UTC)
commit 2e5cb6f52242a235f09d0b72954ed06591c01c06
Author: Ryan Lortie <desrt desrt ca>
Date: Tue Oct 4 15:44:48 2011 -0400
win32 fixes from g_thread_init() deprecation
I can't even begin to imagine how these fell through the cracks...
glib/gmessages.c | 4 ----
glib/gthread-win32.c | 2 +-
glib/gutils.c | 23 +----------------------
3 files changed, 2 insertions(+), 27 deletions(-)
---
diff --git a/glib/gmessages.c b/glib/gmessages.c
index 5a5669f..ae1510b 100644
--- a/glib/gmessages.c
+++ b/glib/gmessages.c
@@ -74,10 +74,8 @@
#ifdef G_OS_WIN32
#include <process.h> /* For getpid() */
#include <io.h>
-# define STRICT /* Strict typing, please */
# define _WIN32_WINDOWS 0x0401 /* to get IsDebuggerPresent */
# include <windows.h>
-# undef STRICT
#endif
@@ -114,9 +112,7 @@ static gpointer fatal_log_data;
/* --- functions --- */
#ifdef G_OS_WIN32
-# define STRICT
# include <windows.h>
-# undef STRICT
static gboolean win32_keep_fatal_message = FALSE;
/* This default message will usually be overwritten. */
diff --git a/glib/gthread-win32.c b/glib/gthread-win32.c
index efd0a70..8607431 100644
--- a/glib/gthread-win32.c
+++ b/glib/gthread-win32.c
@@ -1071,7 +1071,7 @@ g_thread_lookup_native_funcs (void)
}
G_GNUC_INTERNAL void
-g_thread_DllMain (void)
+g_thread_win32_init (void)
{
if (g_thread_lookup_native_funcs ())
fprintf (stderr, "(debug) GThread using native mode\n");
diff --git a/glib/gutils.c b/glib/gutils.c
index 0a66998..cfafbfd 100644
--- a/glib/gutils.c
+++ b/glib/gutils.c
@@ -99,6 +99,7 @@
#define __G_UTILS_C__
#include "gutils.h"
+#include "glib-init.h"
#include "gfileutils.h"
#include "ghash.h"
#include "gslist.h"
@@ -137,9 +138,7 @@
#endif
#ifdef G_PLATFORM_WIN32
-# define STRICT /* Strict typing, please */
# include <windows.h>
-# undef STRICT
# ifndef GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS
# define GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT 2
# define GET_MODULE_HANDLE_EX_FLAG_FROM_ADDRESS 4
@@ -191,26 +190,6 @@ const guint glib_binary_age = GLIB_BINARY_AGE;
#ifdef G_PLATFORM_WIN32
-static HMODULE glib_dll = NULL;
-
-#ifdef DLL_EXPORT
-
-BOOL WINAPI
-DllMain (HINSTANCE hinstDLL,
- DWORD fdwReason,
- LPVOID lpvReserved)
-{
- if (fdwReason == DLL_PROCESS_ATTACH)
- {
- glib_dll = hinstDLL;
- g_thread_DllMain ();
- }
-
- return TRUE;
-}
-
-#endif
-
gchar *
_glib_get_dll_directory (void)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]