Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mono / metadata / w32process-unix-default.c
index 2bb37261ef65c85ce9001ab012c0deade9d52415..91e1d218ad5dc60905cc1442759788ed2713e30d 100644 (file)
@@ -1,3 +1,6 @@
+/**
+ * \file
+ */
 
 #include "w32process.h"
 #include "w32process-unix-internals.h"
@@ -6,7 +9,7 @@
 
 #include <unistd.h>
 
-#ifdef PLATFORM_SOLARIS
+#ifdef HOST_SOLARIS
 /* procfs.h cannot be included if this define is set, but it seems to work fine if it is undefined */
 #if _FILE_OFFSET_BITS == 64
 #undef _FILE_OFFSET_BITS
@@ -38,7 +41,7 @@ mono_w32process_get_name (pid_t pid)
        gchar buf[256];
        gchar *ret = NULL;
 
-#if defined(PLATFORM_SOLARIS)
+#if defined(HOST_SOLARIS)
        filename = g_strdup_printf ("/proc/%d/psinfo", pid);
        if ((fp = fopen (filename, "r")) != NULL) {
                struct psinfo info;
@@ -149,8 +152,10 @@ mono_w32process_get_modules (pid_t pid)
        guint64 device;
 
        fp = open_process_map (pid, "r");
-       if (!fp)
+       if (!fp) {
+               mono_trace (G_LOG_LEVEL_DEBUG, MONO_TRACE_IO_LAYER, "%s: Can't open process map file for pid %d", __func__, pid);
                return NULL;
+       }
 
        while (fgets (buf, sizeof(buf), fp)) {
                p = buf;