ruby-changes:7581
From: ko1 <ko1@a...>
Date: Thu, 4 Sep 2008 00:07:16 +0900 (JST)
Subject: [ruby-changes:7581] Ruby:r19102 (trunk): * win32/win32.c: fix ruby/signal.h depending codes.
ko1 2008-09-04 00:06:55 +0900 (Thu, 04 Sep 2008) New Revision: 19102 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=19102 Log: * win32/win32.c: fix ruby/signal.h depending codes. Modified files: trunk/ChangeLog trunk/win32/win32.c Index: ChangeLog =================================================================== --- ChangeLog (revision 19101) +++ ChangeLog (revision 19102) @@ -1,3 +1,7 @@ +Thu Sep 4 00:04:59 2008 Koichi Sasada <ko1@a...> + + * win32/win32.c: fix ruby/signal.h depending codes. + Thu Sep 4 00:01:45 2008 Yusuke Endoh <mame@t...> * test/etc/test_etc.rb (test_getpwuid, test_getgrgid): use Index: win32/win32.c =================================================================== --- win32/win32.c (revision 19101) +++ win32/win32.c (revision 19102) @@ -11,7 +11,6 @@ */ #include "ruby/ruby.h" -#include "ruby/signal.h" #include "dln.h" #include <fcntl.h> #include <process.h> @@ -74,6 +73,8 @@ #define rb_w32_open_osfhandle(osfhandle, flags) _open_osfhandle(osfhandle, flags) #endif +#define RUBY_CRITICAL(expr) do { expr; } while (0) + /* errno mapping */ static struct { DWORD winerr; @@ -3766,13 +3767,11 @@ int read(int fd, void *buf, size_t size) { - int trap_immediate = rb_trap_immediate; int ret = _read(fd, buf, size); if ((ret < 0) && (errno == EPIPE)) { errno = 0; ret = 0; } - rb_trap_immediate = trap_immediate; catch_interrupt(); return ret; } @@ -3782,11 +3781,10 @@ int rb_w32_getc(FILE* stream) { - int c, trap_immediate = rb_trap_immediate; + int c; #ifndef _WIN32_WCE if (enough_to_get(stream->FILE_COUNT)) { c = (unsigned char)*stream->FILE_READPTR++; - rb_trap_immediate = trap_immediate; } else #endif @@ -3797,7 +3795,6 @@ clearerr(stream); } #endif - rb_trap_immediate = trap_immediate; catch_interrupt(); } return c; @@ -3807,17 +3804,14 @@ int rb_w32_putc(int c, FILE* stream) { - int trap_immediate = rb_trap_immediate; #ifndef _WIN32_WCE if (enough_to_put(stream->FILE_COUNT)) { c = (unsigned char)(*stream->FILE_READPTR++ = (char)c); - rb_trap_immediate = trap_immediate; } else #endif { c = _flsbuf(c, stream); - rb_trap_immediate = trap_immediate; catch_interrupt(); } return c; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/