diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-04-17 15:39:37 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2000-04-17 15:39:37 +0000 |
commit | cd09e4abd8f8ba814e093bfad9519fc7c05f03d9 (patch) | |
tree | fcf40b4dd1aa266835e23ced54448c1d170e54a4 | |
parent | 6d77e51b17a29daf71c329cccdbaee1c140b101d (diff) | |
download | ruby-cd09e4abd8f8ba814e093bfad9519fc7c05f03d9.tar.gz |
2000-04-18
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@670 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | eval.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -6359,8 +6359,10 @@ thread_free(th) th->stk_ptr = 0; if (th->locals) st_free_table(th->locals); if (th->status != THREAD_KILLED) { - th->prev->next = th->next; - th->next->prev = th->prev; + if (th->prev) + th->prev->next = th->next; + if (th->next) + th->next->prev = th->prev; } if (th != main_thread) free(th); } |