From 002fb8f747933409b05b805a9903dcbc7a72abbd Mon Sep 17 00:00:00 2001 From: ko1 Date: Sun, 29 Jun 2008 17:13:37 +0000 Subject: [PATCH] * process.c (Init_process): fix to avoid a warning. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 4 ++++ process.c | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index e3ecd143c0..2812282e58 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +Mon Jun 30 02:10:32 2008 Koichi Sasada + + * process.c (Init_process): fix to avoid a warning. + Mon Jun 30 01:52:05 2008 Yusuke Endoh * test/ruby/test_parse.rb: remove tests for open_args. diff --git a/process.c b/process.c index 38011151dd..1735df827d 100644 --- a/process.c +++ b/process.c @@ -5152,12 +5152,12 @@ Init_process(void) rb_define_module_function(rb_mProcess, "setrlimit", proc_setrlimit, -1); #ifdef RLIM2NUM { - VALUE inf = RLIM2NUM(RLIM_INFINITY), v; - rb_define_const(rb_mProcess, "RLIM_INFINITY", inf); + VALUE inf = RLIM2NUM(RLIM_INFINITY); #ifdef RLIM_SAVED_MAX - v = RLIM_INFINITY == RLIM_SAVED_MAX ? inf : RLIM2NUM(RLIM_SAVED_MAX); + VALUE v = RLIM_INFINITY == RLIM_SAVED_MAX ? inf : RLIM2NUM(RLIM_SAVED_MAX); rb_define_const(rb_mProcess, "RLIM_SAVED_MAX", v); #endif + rb_define_const(rb_mProcess, "RLIM_INFINITY", inf); #ifdef RLIM_SAVED_CUR v = RLIM_INFINITY == RLIM_SAVED_CUR ? inf : RLIM2NUM(RLIM_SAVED_CUR); rb_define_const(rb_mProcess, "RLIM_SAVED_CUR", v);