Commit 10ee4469 authored by Orvid King's avatar Orvid King Committed by Facebook GitHub Bot

Include process.h in portability/Unistd.h

Summary: In newer versions of the windows STL, this gets included in <thread>, so explicitly include it in Unistd.h and remove the definition of getpid.

Reviewed By: yfeldblum

Differential Revision: D23498073

fbshipit-source-id: 5fe07dbbaa9fb1bf5c904286bd15beccbf1d1615
parent 4bf029a2
......@@ -119,10 +119,6 @@ int getgid() {
return 1;
}
pid_t getpid() {
return (pid_t)uint64_t(GetCurrentProcessId());
}
// No major need to implement this, and getting a non-potentially
// stale ID on windows is a bit involved.
pid_t getppid() {
......
......@@ -24,6 +24,8 @@
#include <cstdint>
#include <process.h> // @manual
#include <sys/locking.h> // @manual
#include <folly/Portability.h>
......@@ -69,7 +71,6 @@ int ftruncate(int fd, off_t len);
char* getcwd(char* buf, int sz);
int getdtablesize();
int getgid();
pid_t getpid();
pid_t getppid();
int getuid();
int isatty(int fh);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment