diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2010-04-14 07:03:55 +0200 |
---|---|---|
committer | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2010-09-10 18:40:48 +1000 |
commit | 8677ef15d85c1e0b713c4f97979c696580bcc4f7 (patch) | |
tree | f123db1d5aa8f0a4983c8ee7d7c43cce2ec86c38 /win32 | |
parent | 1223cf253536c4b9ac169019a30bed1fd5adf22e (diff) | |
download | busybox-w32-8677ef15d85c1e0b713c4f97979c696580bcc4f7.tar.gz busybox-w32-8677ef15d85c1e0b713c4f97979c696580bcc4f7.tar.bz2 busybox-w32-8677ef15d85c1e0b713c4f97979c696580bcc4f7.zip |
win32: add waitpid()
Diffstat (limited to 'win32')
-rw-r--r-- | win32/Kbuild | 1 | ||||
-rw-r--r-- | win32/process.c | 10 |
2 files changed, 11 insertions, 0 deletions
diff --git a/win32/Kbuild b/win32/Kbuild index 85f5ca7c4..22f8252d0 100644 --- a/win32/Kbuild +++ b/win32/Kbuild | |||
@@ -6,3 +6,4 @@ lib-y:= | |||
6 | 6 | ||
7 | lib-$(CONFIG_PLATFORM_MINGW32) += fnmatch.o | 7 | lib-$(CONFIG_PLATFORM_MINGW32) += fnmatch.o |
8 | lib-$(CONFIG_PLATFORM_MINGW32) += mingw.o | 8 | lib-$(CONFIG_PLATFORM_MINGW32) += mingw.o |
9 | lib-$(CONFIG_PLATFORM_MINGW32) += process.o | ||
diff --git a/win32/process.c b/win32/process.c new file mode 100644 index 000000000..77d19fb9a --- /dev/null +++ b/win32/process.c | |||
@@ -0,0 +1,10 @@ | |||
1 | #include "libbb.h" | ||
2 | |||
3 | int waitpid(pid_t pid, int *status, unsigned options) | ||
4 | { | ||
5 | /* Windows does not understand parent-child */ | ||
6 | if (options == 0 && pid != -1) | ||
7 | return _cwait(status, pid, 0); | ||
8 | errno = EINVAL; | ||
9 | return -1; | ||
10 | } | ||