Author: dick
Date: 2005-03-09 04:38:44 -0500 (Wed, 09 Mar 2005)
New Revision: 41589

Modified:
   trunk/mono/mono/io-layer/ChangeLog
   trunk/mono/mono/io-layer/daemon.c
Log:

2005-03-09  Dick Porter  <[EMAIL PROTECTED]>

        * daemon.c (process_process_fork): Initialise the handle data
        before using it in the error case.  This is probably the error
        we're working around in the previous change.  Spotted by Taru Jain
        <[EMAIL PROTECTED]> and Hemanth Yamijala <[EMAIL PROTECTED]>.




Modified: trunk/mono/mono/io-layer/ChangeLog
===================================================================
--- trunk/mono/mono/io-layer/ChangeLog  2005-03-09 09:18:13 UTC (rev 41588)
+++ trunk/mono/mono/io-layer/ChangeLog  2005-03-09 09:38:44 UTC (rev 41589)
@@ -1,3 +1,10 @@
+2005-03-09  Dick Porter  <[EMAIL PROTECTED]>
+
+       * daemon.c (process_process_fork): Initialise the handle data
+       before using it in the error case.  This is probably the error
+       we're working around in the previous change.  Spotted by Taru Jain
+       <[EMAIL PROTECTED]> and Hemanth Yamijala <[EMAIL PROTECTED]>.
+
 2005-03-07  Dick Porter  <[EMAIL PROTECTED]>
 
        * daemon.c: It looks like g_shell_parse_argv() can return

Modified: trunk/mono/mono/io-layer/daemon.c
===================================================================
--- trunk/mono/mono/io-layer/daemon.c   2005-03-09 09:18:13 UTC (rev 41588)
+++ trunk/mono/mono/io-layer/daemon.c   2005-03-09 09:38:44 UTC (rev 41589)
@@ -1104,6 +1104,16 @@
                cmd=_wapi_handle_scratch_lookup (process_fork.cmd);
                dir=_wapi_handle_scratch_lookup (process_fork.dir);
                env=_wapi_handle_scratch_lookup_string_array (process_fork.env);
+
+               _wapi_lookup_handle (GUINT_TO_POINTER (process_handle),
+                                    WAPI_HANDLE_PROCESS,
+                                    (gpointer *)&process_handle_data,
+                                    NULL);
+
+               _wapi_lookup_handle (GUINT_TO_POINTER (thread_handle),
+                                    WAPI_HANDLE_THREAD,
+                                    (gpointer *)&thread_handle_data,
+                                    NULL);
                
                ret=g_shell_parse_argv (cmd, NULL, &argv, &gerr);
                if(ret==FALSE) {
@@ -1116,16 +1126,6 @@
                        g_message (G_GNUC_PRETTY_FUNCTION ": forking");
 #endif
 
-                       _wapi_lookup_handle (GUINT_TO_POINTER (process_handle),
-                                            WAPI_HANDLE_PROCESS,
-                                            (gpointer *)&process_handle_data,
-                                            NULL);
-
-                       _wapi_lookup_handle (GUINT_TO_POINTER (thread_handle),
-                                            WAPI_HANDLE_THREAD,
-                                            (gpointer *)&thread_handle_data,
-                                            NULL);
-
                        /* Fork, exec cmd with args and optional env,
                         * and return the handles with pid and blank
                         * thread id

_______________________________________________
Mono-patches maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches

Reply via email to