summaryrefslogtreecommitdiff
path: root/ext/pty
diff options
context:
space:
mode:
authorko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-02-05 16:22:38 +0000
committerko1 <ko1@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-02-05 16:22:38 +0000
commit27172b8e6fcd14f07fa5ea5be803cb04bde04559 (patch)
tree38c4e091c97426157118d2eaf8d5d6c0edbabf17 /ext/pty
parent48002b881e49ff76f869e0f383fd5419cbca9af3 (diff)
* intern.h: prepare rb_last_status_get() and rb_last_status_set().
Use these functions instead of rb_last_status ([ruby-dev:30264]). * process.c: define above functions. * ext/pty/pty.c: use above functins. * io.c (pipe_finalize): ditto. * process.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11633 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/pty')
-rw-r--r--ext/pty/pty.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/ext/pty/pty.c b/ext/pty/pty.c
index 215f2cfd6d..5d86525daa 100644
--- a/ext/pty/pty.c
+++ b/ext/pty/pty.c
@@ -135,13 +135,12 @@ struct pty_info {
static void
raise_from_wait(char *state, struct pty_info *info)
{
- extern VALUE rb_last_status;
char buf[1024];
VALUE exc;
snprintf(buf, sizeof(buf), "pty - %s: %ld", state, (long)info->child_pid);
exc = rb_exc_new2(eChildExited, buf);
- rb_iv_set(exc, "status", rb_last_status);
+ rb_iv_set(exc, "status", rb_last_status_get());
rb_funcall(info->thread, rb_intern("raise"), 1, exc);
}