summaryrefslogtreecommitdiffstats
path: root/eval.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-08-02 09:22:27 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-08-02 09:22:27 +0000
commitf59fe4bae5630650d6cbeec6de32b27c7be459c0 (patch)
tree17e1f9d1a3b3f471e806310ea15f84c8d9ea998c /eval.c
parent2f592086532d3d9bb03288bd5d51a7baf46836df (diff)
downloadruby-f59fe4bae5630650d6cbeec6de32b27c7be459c0.tar.gz
ruby-f59fe4bae5630650d6cbeec6de32b27c7be459c0.tar.xz
ruby-f59fe4bae5630650d6cbeec6de32b27c7be459c0.zip
matz
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@870 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval.c')
-rw-r--r--eval.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/eval.c b/eval.c
index 31f469407..f4b2328dd 100644
--- a/eval.c
+++ b/eval.c
@@ -8110,6 +8110,9 @@ rb_cont_call(argc, argv, cont)
{
rb_thread_t th = rb_thread_check(cont);
+ if (th->next != curr_thread) {
+ rb_raise(rb_eRuntimeError, "continuation called across threads");
+ }
switch (argc) {
case 0:
th->result = Qnil;