ruby-changes:36688
From: nobu <ko1@a...>
Date: Thu, 11 Dec 2014 12:02:54 +0900 (JST)
Subject: [ruby-changes:36688] nobu:r48769 (trunk): process.c: unused variables
nobu 2014-12-11 12:02:36 +0900 (Thu, 11 Dec 2014) New Revision: 48769 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=48769 Log: process.c: unused variables * process.c (rb_fork_async_signal_safe): remove initialized but never assigned local variables. Modified files: trunk/process.c Index: process.c =================================================================== --- process.c (revision 48768) +++ process.c (revision 48769) @@ -3580,9 +3580,8 @@ rb_fork_async_signal_safe(int *status, i https://github.com/ruby/ruby/blob/trunk/process.c#L3580 char *errmsg, size_t errmsg_buflen) { rb_pid_t pid; - int err, state = 0; + int err; int ep[2]; - VALUE exc = Qnil; int error_occurred; if (status) *status = 0; @@ -3593,14 +3592,12 @@ rb_fork_async_signal_safe(int *status, i https://github.com/ruby/ruby/blob/trunk/process.c#L3592 return pid; close(ep[1]); error_occurred = recv_child_error(ep[0], &err, errmsg, errmsg_buflen); - if (state || error_occurred) { + if (error_occurred) { if (status) { rb_protect(proc_syswait, (VALUE)pid, status); - if (state) *status = state; } else { rb_syswait(pid); - if (state) rb_exc_raise(exc); } errno = err; return -1; -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/