blob: d03987d6b5ab8f6a3e16a1b72d73d04e0f931956 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
$NetBSD: patch-mozilla_ipc_chromium_src_base_process__util.h,v 1.9 2013/08/11 03:18:46 ryoon Exp $
--- mozilla/ipc/chromium/src/base/process_util.h.orig 2013-08-04 03:05:29.000000000 +0000
+++ mozilla/ipc/chromium/src/base/process_util.h
@@ -13,7 +13,7 @@
#if defined(OS_WIN)
#include <windows.h>
#include <tlhelp32.h>
-#elif defined(OS_LINUX)
+#elif defined(OS_LINUX) || defined(OS_SOLARIS)
#include <dirent.h>
#include <limits.h>
#include <sys/types.h>
@@ -32,6 +32,9 @@
typedef PROCESSENTRY32 ProcessEntry;
typedef IO_COUNTERS IoCounters;
#elif defined(OS_POSIX)
+#ifndef NAME_MAX
+#define NAME_MAX _POSIX_NAME_MAX
+#endif
// TODO(port): we should not rely on a Win32 structure.
struct ProcessEntry {
int pid;
@@ -316,7 +319,7 @@ class NamedProcessIterator {
#if defined(OS_WIN)
HANDLE snapshot_;
bool started_iteration_;
-#elif defined(OS_LINUX)
+#elif defined(OS_LINUX) || defined(OS_SOLARIS)
DIR *procfs_dir_;
#elif defined(OS_BSD)
std::vector<ProcessEntry> content;
|