From f105b741e549e2c2b985e1458ff6153c3d13929a Mon Sep 17 00:00:00 2001 From: athenian200 Date: Tue, 1 Oct 2019 19:15:26 -0500 Subject: MoonchildProductions#1251 - Part 5: Fix POSIX compliance issue in process_util.h. https://bugzilla.mozilla.org/show_bug.cgi?id=1364865 Solaris doesn't define NAME_MAX because if you read the current POSIX standard literally, no system that supports multiple file systems or networking should be defining it. It's a pedantic choice given that they USED to define NAME_MAX, but Solaris always did take POSIX compliance seriously, for better or worse. --- ipc/chromium/src/base/process_util.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'ipc/chromium/src') diff --git a/ipc/chromium/src/base/process_util.h b/ipc/chromium/src/base/process_util.h index 2b257b587..9b1e4fed5 100644 --- a/ipc/chromium/src/base/process_util.h +++ b/ipc/chromium/src/base/process_util.h @@ -44,10 +44,12 @@ typedef PROCESSENTRY32 ProcessEntry; typedef IO_COUNTERS IoCounters; #elif defined(OS_POSIX) // TODO(port): we should not rely on a Win32 structure. +// Using NAME_MAX here would raise POSIX compliance issues +// (see Mozilla bug 1364865). struct ProcessEntry { int pid; int ppid; - char szExeFile[NAME_MAX + 1]; + char szExeFile[_POSIX_PATH_MAX + 1]; }; struct IoCounters { -- cgit v1.2.3