Project

General

Profile

Bug #5526

SEGV: ./ruby -rfiber -ve'f=Fiber.new{f.resume};f.transfer'

Added by naruse (Yui NARUSE) over 7 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Target version:
-
ruby -v:
ruby -v: ruby 2.0.0dev (2011-10-31 trunk 33581) [x86_64-freebsd8.2]
Backport:
[ruby-dev:44742]

Description

FreeBSD 9 にて、./ruby -rfiber -ve'f=Fiber.new{f.resume};f.transfer' で SEGV します。
他のプラットフォームでも dead fiber call 例外なのはおかしくて、
double resume 例外になるべきでしょう。

Associated revisions

Revision 9cd8b76e
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33684 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

Revision 33684
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Revision 33684
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Revision 33684
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Revision 33684
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Revision 33684
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Revision 33684
Added by ko1 (Koichi Sasada) over 7 years ago

  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Revision 4bfa061e
Added by naruse (Yui NARUSE) over 7 years ago

Partially revert r27949.

  • cont.c (fiber_setcontext): Use longjmp() instead of swapcontext() on FreeBSD 9. [ruby-dev:41316] [Bug #3295] [Bug #5526]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_9_3@34530 b2dd03c8-39d4-4d8f-98ff-823fe69b080e

History

#1

Updated by ko1 (Koichi Sasada) over 7 years ago

  • Status changed from Assigned to Closed
  • % Done changed from 0 to 100

This issue was solved with changeset r33684.
Yui, thank you for reporting this issue.
Your contribution to Ruby is greatly appreciated.
May Ruby be with you.


  • cont.c (rb_fiber_m_transfer, rb_fiber_resume): prohibit using "resume" after "transfer" method are used. You should not mix "resume" fiber and "transfer" fiber. [Bug #5526]
  • NEWS: add information about this change.

Also available in: Atom PDF