--- gspawn-win32-helper.c.orig	2009-03-12 21:09:59.000000000 -0700
+++ gspawn-win32-helper.c	2009-03-15 17:15:54.138721279 -0700
@@ -147,6 +147,16 @@
   return argc;
 }
 
+static void
+ignore_invalid_param(const wchar_t *expression,
+		     const wchar_t *function,
+		     const wchar_t *file,
+		     unsigned int   line,
+		     uintptr_t      pReserved)
+{
+
+}
+
 #ifndef HELPER_CONSOLE
 int _stdcall
 WinMain (struct HINSTANCE__ *hInstance,
@@ -174,6 +184,7 @@
   char c;
 
   g_assert (__argc >= ARG_COUNT);
+  _set_invalid_parameter_handler(ignore_invalid_param);
 
   /* Fetch the wide-char argument vector */
   __wgetmainargs (&argc, &wargv, &wenvp, 0, &si);
