diff -urN glib-2.38.2/gio/giomodule.c glib-2.38.2-win32/gio/giomodule.c
--- glib-2.38.2/gio/giomodule.c	2013-11-12 06:30:22.000000000 +0100
+++ glib-2.38.2-win32/gio/giomodule.c	2014-01-02 01:39:29.000000000 +0100
@@ -897,6 +897,7 @@
 #ifdef G_PLATFORM_WIN32
 
 #include <windows.h>
+extern GType _g_network_monitor_windows_get_type (void);
 
 static HMODULE gio_dll = NULL;
 
@@ -1079,6 +1080,9 @@
 #ifdef HAVE_NETLINK
       g_type_ensure (_g_network_monitor_netlink_get_type ());
 #endif
+#ifdef G_OS_WIN32
+      g_type_ensure (_g_network_monitor_windows_get_type ());
+#endif
     }
 
   G_UNLOCK (loaded_dirs);
diff -urN glib-2.38.2/gio/gnetworkmonitorwindows.c glib-2.38.2-win32/gio/gnetworkmonitorwindows.c
--- glib-2.38.2/gio/gnetworkmonitorwindows.c	1970-01-01 01:00:00.000000000 +0100
+++ glib-2.38.2-win32/gio/gnetworkmonitorwindows.c	2014-01-02 15:22:44.000000000 +0100
@@ -0,0 +1,384 @@
+/* GIO - GLib Input, Output and Streaming Library
+ *
+ * Copyright 2014 Jan-Michael Brummer <jan.brummer@tabos.org>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General
+ * Public License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#include "config.h"
+
+#include <errno.h>
+#include <unistd.h>
+
+#include <winsock2.h>
+#include <ws2tcpip.h>
+#include <iphlpapi.h>
+#include <stdio.h>
+
+#include "gnetworkmonitorwindows.h"
+#include "ginetaddress.h"
+#include "ginetaddressmask.h"
+#include "ginitable.h"
+#include "giomodule-priv.h"
+#include "glibintl.h"
+#include "glib/gstdio.h"
+#include "gnetworkingprivate.h"
+#include "gsocket.h"
+#include "gnetworkmonitor.h"
+
+static void g_network_monitor_windows_iface_init (GNetworkMonitorInterface *iface);
+static void g_network_monitor_windows_initable_iface_init (GInitableIface *iface);
+
+struct _GNetworkMonitorWindowsPrivate
+{
+  PMIB_IPFORWARDTABLE  table;
+  OVERLAPPED           overlap;
+
+  GThread             *thread;
+  gboolean             quit;
+};
+
+#define g_network_monitor_windows_get_type _g_network_monitor_windows_get_type
+G_DEFINE_TYPE_WITH_CODE (GNetworkMonitorWindows, g_network_monitor_windows, G_TYPE_NETWORK_MONITOR_BASE,
+                         G_ADD_PRIVATE (GNetworkMonitorWindows)
+                         G_IMPLEMENT_INTERFACE (G_TYPE_NETWORK_MONITOR,
+                                                g_network_monitor_windows_iface_init)
+                         G_IMPLEMENT_INTERFACE (G_TYPE_INITABLE,
+                                                g_network_monitor_windows_initable_iface_init)
+                         _g_io_modules_ensure_extension_points_registered ();
+                         g_io_extension_point_implement (G_NETWORK_MONITOR_EXTENSION_POINT_NAME,
+                                                         g_define_type_id,
+                                                         "windows",
+                                                         20))
+
+static void
+g_network_monitor_windows_init (GNetworkMonitorWindows *win)
+{
+  win->priv = g_network_monitor_windows_get_instance_private (win);
+}
+
+static void
+add_network (GNetworkMonitorWindows *win,
+             GSocketFamily           family,
+             gint                    dest_len,
+             guint8                 *dest)
+{
+  GInetAddress *dest_addr;
+  GInetAddressMask *network;
+
+  if (dest)
+    dest_addr = g_inet_address_new_from_bytes (dest, family);
+  else
+    dest_addr = g_inet_address_new_any (family);
+
+  network = g_inet_address_mask_new (dest_addr, dest_len, NULL);
+  g_object_unref (dest_addr);
+  g_return_if_fail (network != NULL);
+
+  g_network_monitor_base_add_network (G_NETWORK_MONITOR_BASE (win), network);
+  g_object_unref (network);
+}
+
+static void
+remove_network (GNetworkMonitorWindows *win,
+                GSocketFamily           family,
+                gint                    dest_len,
+                guint8                 *dest)
+{
+  GInetAddress *dest_addr;
+  GInetAddressMask *network;
+
+  if (dest)
+    dest_addr = g_inet_address_new_from_bytes (dest, family);
+  else
+    dest_addr = g_inet_address_new_any (family);
+
+  network = g_inet_address_mask_new (dest_addr, dest_len, NULL);
+  g_object_unref (dest_addr);
+  g_return_if_fail (network != NULL);
+
+  g_network_monitor_base_remove_network (G_NETWORK_MONITOR_BASE (win), network);
+  g_object_unref (network);
+}
+
+static PMIB_IPFORWARDTABLE
+win_network_monitor_read_forward_table (void)
+{
+  PMIB_IPFORWARDTABLE ip_forward_table;
+  DWORD ret = 0;
+  DWORD size = 0;
+
+  /* Try to read the table with the default size */
+  ip_forward_table = g_malloc (sizeof (MIB_IPFORWARDTABLE));
+
+  ret = GetIpForwardTable (ip_forward_table, &size, 0);
+  if (ret == ERROR_INSUFFICIENT_BUFFER)
+    {
+      g_free (ip_forward_table);
+
+      /* The above command failed due to insufficient buffer space.
+       * As "size" contains the needed buffer size, try to allocate
+       * it.
+       */
+      ip_forward_table = g_malloc (size);
+
+      ret = GetIpForwardTable (ip_forward_table, &size, 0);
+    }
+
+  if (ret != NO_ERROR)
+    {
+      g_warning("GetIpForwardTable () failed: %ld\n", ret);
+      g_free (ip_forward_table);
+
+      return NULL;
+    }
+
+  return ip_forward_table;
+}
+
+static gint
+win_network_monitor_mask_get_len(gulong addr)
+{
+  gint i;
+  gint count = 0;
+  gboolean add = TRUE;
+
+  for (i = 31; i >= 0; i--)
+    {
+      if (addr & (1<<i))
+        {
+          if (add)
+            {
+              count++;
+            }
+        }
+       else if (count)
+         {
+           add = FALSE;
+         }
+    }
+
+    return count;
+}
+
+static void
+win_network_monitor_process_table (GNetworkMonitorWindows *win,
+                                   PMIB_IPFORWARDTABLE table,
+                                   int init)
+{
+  gint i, j;
+  gint len;
+  gint found = 0;
+
+  /* Entries added */
+  if (init || (table->dwNumEntries > win->priv->table->dwNumEntries))
+    {
+      for (i = 0; i < table->dwNumEntries; i++)
+        {
+          if (init || !table->table[i].dwForwardAge)
+            {
+              len = win_network_monitor_mask_get_len(table->table[i].dwForwardMask);
+
+              add_network (win, G_SOCKET_FAMILY_IPV4, len,
+                           (guint8 *) &table->table[i].dwForwardDest);
+            }
+        }
+    }
+  else if (table->dwNumEntries < win->priv->table->dwNumEntries)
+    {
+      /* Traverse old list and find removed entries */
+      for (i = 0; i < win->priv->table->dwNumEntries; i++)
+        {
+          GInetAddress *dest_addr;
+          GInetAddressMask *network;
+          guint8 *dest = (guint8 *) &win->priv->table->table[i].dwForwardDest;
+          gint family = G_SOCKET_FAMILY_IPV4;
+
+          if (dest)
+            dest_addr = g_inet_address_new_from_bytes (dest, family);
+          else
+            dest_addr = g_inet_address_new_any (family);
+
+          len = win_network_monitor_mask_get_len(win->priv->table->table[i].dwForwardMask);
+          network = g_inet_address_mask_new (dest_addr, len, NULL);
+          g_object_unref (dest_addr);
+          g_return_if_fail (network != NULL);
+
+          found = FALSE;
+
+          for (j = 0; j < table->dwNumEntries; j++)
+            {
+              GInetAddress *check_dest_addr;
+              GInetAddressMask *check_network;
+              guint8 *check_dest = (guint8 *) &table->table[j].dwForwardDest;
+              gint check_family = G_SOCKET_FAMILY_IPV4;
+
+              if (check_dest)
+                check_dest_addr = g_inet_address_new_from_bytes (check_dest, check_family);
+              else
+                check_dest_addr = g_inet_address_new_any (check_family);
+
+              len = win_network_monitor_mask_get_len(table->table[j].dwForwardMask);
+              check_network = g_inet_address_mask_new (check_dest_addr, len, NULL);
+              g_object_unref (check_dest_addr);
+              g_return_if_fail (check_network != NULL);
+
+              if (g_inet_address_mask_equal(network, check_network))
+                {
+                  g_object_unref (check_network);
+                  found = TRUE;
+                  break;
+                }
+
+               g_object_unref (check_network);
+             }
+
+          if (!found)
+            {
+              len = win_network_monitor_mask_get_len(win->priv->table->table[i].dwForwardMask);
+
+              remove_network (win, G_SOCKET_FAMILY_IPV4, len,
+                                (guint8 *) &win->priv->table->table[i].dwForwardDest);
+            }
+
+          g_object_unref (network);
+        }
+    }
+}
+
+static int
+win_network_monitor_request_update (GNetworkMonitorWindows *win)
+{
+  DWORD ret;
+  HANDLE hand;
+
+  ret = NotifyRouteChange (&hand, &win->priv->overlap);
+  if (ret != NO_ERROR)
+    {
+      if (WSAGetLastError () != WSA_IO_PENDING)
+        {
+          g_warning("NotifyRouteChange error...%d\n", WSAGetLastError ());
+          return 1;
+        }
+    }
+
+  return 0;
+}
+
+static gpointer
+win_network_monitor_thread_func (gpointer data)
+{
+  GNetworkMonitorWindows *win = data;
+
+  do {
+    /* Wait for network change event */
+    if (WaitForSingleObject (win->priv->overlap.hEvent, INFINITE) ==
+      WAIT_OBJECT_0)
+      {
+        PMIB_IPFORWARDTABLE table;
+
+        table = win_network_monitor_read_forward_table ();
+
+        win_network_monitor_process_table (win, table, 0);
+
+        /* It is fine to to this without locking as the next event isn't
+         * requested yet
+         */
+        free (win->priv->table);
+        win->priv->table = table;
+      }
+
+    /* After receiving an event, we must re-request our notification */
+    if (win_network_monitor_request_update (win))
+      {
+        /* An error occurred on re-requesting the notification, abort */
+        break;
+      }
+  } while (!win->priv->quit);
+
+  return NULL;
+}
+
+static gboolean
+g_network_monitor_windows_initable_init (GInitable     *initable,
+                                         GCancellable  *cancellable,
+                                         GError       **error)
+{
+  GNetworkMonitorWindows *win = G_NETWORK_MONITOR_WINDOWS (initable);
+
+  /* Read current table, so we have an internal state */
+  win->priv->table = win_network_monitor_read_forward_table ();
+  if (!win->priv->table)
+    {
+      return FALSE;
+    }
+
+  /* Process table */
+  win_network_monitor_process_table (win, win->priv->table, 1);
+
+  /* Create event */
+  win->priv->overlap.hEvent = WSACreateEvent ();
+
+  /* Request an update notification */
+  if (win_network_monitor_request_update (win))
+    {
+        /* An error occurred on requesting the notification, abort */
+        free(win->priv->table);
+        return FALSE;;
+    }
+
+  /* Prepare network update thread */
+  win->priv->quit = FALSE;
+  win->priv->thread = g_thread_new ("windows network monitor",
+                                   win_network_monitor_thread_func,
+                                   win);
+
+  return TRUE;
+}
+
+static void
+g_network_monitor_windows_finalize (GObject *object)
+{
+  GNetworkMonitorWindows *win = G_NETWORK_MONITOR_WINDOWS (object);
+
+  /* Cancel the thread an the notification event */
+  win->priv->quit = TRUE;
+  CancelIPChangeNotify (&win->priv->overlap);
+
+  /* Free table */
+  g_free(win->priv->table);
+
+  G_OBJECT_CLASS (g_network_monitor_windows_parent_class)->finalize (object);
+}
+
+static void
+g_network_monitor_windows_class_init (GNetworkMonitorWindowsClass *win_class)
+{
+  GObjectClass *gobject_class = G_OBJECT_CLASS (win_class);
+
+  gobject_class->finalize = g_network_monitor_windows_finalize;
+}
+
+static void
+g_network_monitor_windows_iface_init (GNetworkMonitorInterface *monitor_iface)
+{
+}
+
+static void
+g_network_monitor_windows_initable_iface_init (GInitableIface *iface)
+{
+  iface->init = g_network_monitor_windows_initable_init;
+}
diff -urN glib-2.38.2/gio/gnetworkmonitorwindows.h glib-2.38.2-win32/gio/gnetworkmonitorwindows.h
--- glib-2.38.2/gio/gnetworkmonitorwindows.h	1970-01-01 01:00:00.000000000 +0100
+++ glib-2.38.2-win32/gio/gnetworkmonitorwindows.h	2014-01-02 00:41:28.000000000 +0100
@@ -0,0 +1,57 @@
+/* GIO - GLib Input, Output and Streaming Library
+ *
+ * Copyright 2014 Jan-Michael Brummer <jan.brummer@tabos.org>
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General
+ * Public License along with this library; if not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place, Suite 330,
+ * Boston, MA 02111-1307, USA.
+ */
+
+#ifndef __G_NETWORK_MONITOR_WINDOWS_H__
+#define __G_NETWORK_MONITOR_WINDOWS_H__
+
+#include "gnetworkmonitorbase.h"
+
+G_BEGIN_DECLS
+
+#define G_TYPE_NETWORK_MONITOR_WINDOWS         (_g_network_monitor_windows_get_type ())
+#define G_NETWORK_MONITOR_WINDOWS(o)           (G_TYPE_CHECK_INSTANCE_CAST ((o), G_TYPE_NETWORK_MONITOR_WINDOWS, GNetworkMonitorWindows))
+#define G_NETWORK_MONITOR_WINDOWS_CLASS(k)     (G_TYPE_CHECK_CLASS_CAST((k), G_TYPE_NETWORK_MONITOR_WINDOWS, GNetworkMonitorWindowsClass))
+#define G_IS_NETWORK_MONITOR_WINDOWS(o)        (G_TYPE_CHECK_INSTANCE_TYPE ((o), G_TYPE_NETWORK_MONITOR_WINDOWS))
+#define G_IS_NETWORK_MONITOR_WINDOWS_CLASS(k)  (G_TYPE_CHECK_CLASS_TYPE ((k), G_TYPE_NETWORK_MONITOR_WINDOWS))
+#define G_NETWORK_MONITOR_WINDOWS_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), G_TYPE_NETWORK_MONITOR_WINDOWS, GNetworkMonitorWindowsClass))
+
+typedef struct _GNetworkMonitorWindows        GNetworkMonitorWindows;
+typedef struct _GNetworkMonitorWindowsClass   GNetworkMonitorWindowsClass;
+typedef struct _GNetworkMonitorWindowsPrivate GNetworkMonitorWindowsPrivate;
+
+struct _GNetworkMonitorWindows {
+  GNetworkMonitorBase parent_instance;
+
+  GNetworkMonitorWindowsPrivate *priv;
+};
+
+struct _GNetworkMonitorWindowsClass {
+  GNetworkMonitorBaseClass parent_class;
+
+  /*< private >*/
+  /* Padding for future expansion */
+  gpointer padding[8];
+};
+
+GType _g_network_monitor_windows_get_type (void);
+
+G_END_DECLS
+
+#endif /* __G_NETWORK_MONITOR_WINDOWS_H__ */
diff -urN glib-2.38.2/gio/Makefile.am glib-2.38.2-win32/gio/Makefile.am
--- glib-2.38.2/gio/Makefile.am	2013-11-12 06:30:22.000000000 +0100
+++ glib-2.38.2-win32/gio/Makefile.am	2014-01-02 00:38:58.000000000 +0100
@@ -317,7 +317,9 @@
 if OS_WIN32
 appinfo_sources += gwin32appinfo.c gwin32appinfo.h
 platform_libadd += -lshlwapi -lws2_32 -ldnsapi -liphlpapi
-win32_sources = $(win32_actual_sources)
+win32_sources = $(win32_actual_sources) \
+	 gnetworkmonitorwindows.c \
+	 gnetworkmonitorwindows.h
 
 giowin32includedir=$(includedir)/gio-win32-2.0/gio
 giowin32include_HEADERS = \
