diff options
author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-07-10 03:10:00 +0000 |
---|---|---|
committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-07-10 03:10:00 +0000 |
commit | 1a5f1a8c6966a973b26b85cb6e1e65ad0c5a5ed1 (patch) | |
tree | 259804fd59dcbf2d7dbe669f850b46f6b8960220 /process.c | |
parent | 7ad9faa5280b0f6e87ef658bc209ffe24fdac85c (diff) | |
download | bundler-1a5f1a8c6966a973b26b85cb6e1e65ad0c5a5ed1.tar.gz |
* vm_core.h (rb_thread_t), vm.c (rb_thread_mark), process.c
(rb_last_status_get, rb_last_status_set, rb_last_status_clear):
moved last_status from rb_vm_t. [ruby-dev:35414]
* vm.c (th_init2): initialize last_status with nil.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'process.c')
-rw-r--r-- | process.c | 13 |
1 files changed, 6 insertions, 7 deletions
@@ -218,23 +218,22 @@ static VALUE rb_cProcessStatus; VALUE rb_last_status_get(void) { - return GET_VM()->last_status; + return GET_THREAD()->last_status; } void rb_last_status_set(int status, rb_pid_t pid) { - rb_vm_t *vm = GET_VM(); - vm->last_status = rb_obj_alloc(rb_cProcessStatus); - rb_iv_set(vm->last_status, "status", INT2FIX(status)); - rb_iv_set(vm->last_status, "pid", PIDT2NUM(pid)); + rb_thread_t *th = GET_THREAD(); + th->last_status = rb_obj_alloc(rb_cProcessStatus); + rb_iv_set(th->last_status, "status", INT2FIX(status)); + rb_iv_set(th->last_status, "pid", PIDT2NUM(pid)); } static void rb_last_status_clear(void) { - rb_vm_t *vm = GET_VM(); - vm->last_status = Qnil; + GET_THREAD()->last_status = Qnil; } /* |