[runtime] Added helper methods to iterate MonoInst with filters.
[mono.git] / mono / mini / wapihandles.c
index c2a31ce1ea3532db21c42ecd459079fa733bfac2..7bda38843ef4d8df290858f41da479d940727c6c 100644 (file)
@@ -3,7 +3,7 @@
 
 #include "mini.h"
 
-#if defined(HOST_WIN32) || !defined(HAVE_SYS_IPC_H) || !defined(HAVE_SYS_SEM_H) || (defined(__native_client__) && defined(__GLIBC__))
+#if defined(HOST_WIN32) || !defined(HAVE_SYS_IPC_H) || !defined(HAVE_SYS_SEM_H) || (defined(__native_client__) && defined(__GLIBC__)) || defined(DISABLE_SHARED_HANDLES)
 
 int mini_wapi_hps (int argc, char **argv)
 {
@@ -42,7 +42,6 @@ static const gchar *thread_details (struct _WapiHandleShared *handle);
 static const gchar *namedmutex_details (struct _WapiHandleShared *handle);
 static const gchar *namedsem_details (struct _WapiHandleShared *handle);
 static const gchar *namedevent_details (struct _WapiHandleShared *handle);
-static const gchar *process_details (struct _WapiHandleShared *handle);
 
 /* This depends on the ordering of the enum WapiHandleType in
  * io-layer/wapi-private.h
@@ -58,7 +57,7 @@ static const gchar * (*details[])(struct _WapiHandleShared *)=
        unshared_details,               /* event */
        unshared_details,               /* socket */
        unshared_details,               /* find */
-       process_details,
+       unshared_details,       /* process */
        unshared_details,               /* pipe */
        namedmutex_details,
        namedsem_details,
@@ -191,20 +190,6 @@ static const gchar *namedevent_details (struct _WapiHandleShared *handle)
        return(buf);
 }
 
-static const gchar *process_details (struct _WapiHandleShared *handle)
-{
-       static gchar buf[80];
-       gchar *name;
-       struct _WapiHandle_process *proc=&handle->u.process;
-       
-       name = proc->proc_name;
-       
-       g_snprintf (buf, sizeof(buf), "[%25.25s] pid: %5u exit: %u",
-                   name==NULL?(gchar *)"":name, proc->id, proc->exitstatus);
-       
-       return(buf);
-}
-
 /* The old handles/semdel.c */
 int mini_wapi_semdel (int argc, char **argv)
 {