summaryrefslogtreecommitdiffstats
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
commit3b8aeff63ea9855f64c7f6c9771c58c68d9fb55f (patch)
tree38c4e091c97426157118d2eaf8d5d6c0edbabf17 /ext/pty
parentbad40cf1ee1edcf05753e3b41f90f8b8a88cfca6 (diff)
downloadruby-3b8aeff63ea9855f64c7f6c9771c58c68d9fb55f.tar.gz
ruby-3b8aeff63ea9855f64c7f6c9771c58c68d9fb55f.tar.xz
ruby-3b8aeff63ea9855f64c7f6c9771c58c68d9fb55f.zip
* 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: http://svn.ruby-lang.org/repos/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 215f2cfd6..5d86525da 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);
}