diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | win32/win32.c | 3 |
2 files changed, 6 insertions, 2 deletions
@@ -1,3 +1,8 @@ +Thu Oct 1 13:23:14 2009 NAKAMURA Usaku <usa@ruby-lang.org> + + * win32/win32.c (rb_w32_getpid): simply call GetCurrentProcessId() + instead of calling MSVCRT's getpid(). + Wed Sep 30 13:15:45 2009 Nobuyoshi Nakada <nobu@ruby-lang.org> * vm_method.c (rb_add_method_def): show the location where diff --git a/win32/win32.c b/win32/win32.c index 222af78c72..d832ef3d6e 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -4426,13 +4426,12 @@ rb_w32_free_environ(char **env) free(env); } -#undef getpid rb_pid_t rb_w32_getpid(void) { rb_pid_t pid; - pid = getpid(); + pid = GetCurrentProcessId(); (void)IfWin95(pid = -pid, 0); |