Project

General

Profile

Backport #5014

Solarisはシグナルハンドラでabortを呼べない

Added by kosaki (Motohiro KOSAKI) about 9 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
[ruby-dev:44082]

Description

後から気づいたのですが、さらにいうと、exit()はasync signal safe じゃないので元々論外でした。
exit()は内部でロック取るのでデッドロックリスクあり。

これを書いていて気づいたのでうsが、困った事にSolarisはabortが async signal safe じゃないので
(もちろんPOSIX違反)、たぶんSolarisのときは _exit()とか使わないとデッドロックするリスクがあります。
環境もってないので、1.9.x に回します。

Updated by kosaki (Motohiro KOSAKI) about 9 years ago

  • Priority changed from Normal to 3

Updated by naruse (Yui NARUSE) about 9 years ago

  • Status changed from Open to Assigned
  • Assignee set to ngoto (Naohisa Goto)

Updated by ko1 (Koichi Sasada) over 7 years ago

  • Target version changed from 2.0.0 to 2.1.0

ごとうさん、こちらいかがでしょうか。

Updated by kosaki (Motohiro KOSAKI) over 7 years ago

  • Assignee changed from ngoto (Naohisa Goto) to kosaki (Motohiro KOSAKI)

これなんだっけ?
たぶん僕がパッチをつくってごとうさんにレビューしてもらうのが確実そう。
というわけで、アサインを変更します。変更方針へのアドバイスは歓迎します。

#6

Updated by kosaki (Motohiro KOSAKI) over 7 years ago

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

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


  • signal.c (sigsegv): avoid to use async signal unsafe functions when nested sigsegv is happen. [Bug #5014] [ruby-dev:44082]

Updated by ngoto (Naohisa Goto) over 7 years ago

r39382 にてtypoの修正をしました。Solarisでのコンパイルは通っています。
動作チェックはどうやればいいんでしょう?

Updated by kosaki (Motohiro KOSAKI) over 7 years ago

あああ、すいませんでした。
動作チェックはsegvハンドラに自分でバグを入れるしかないと思います。

#9

Updated by nagachika (Tomoyuki Chikanaga) over 7 years ago

  • Tracker changed from Bug to Backport
  • Project changed from Ruby master to Backport200
  • Category deleted (core)
  • Status changed from Closed to Assigned
  • Assignee changed from kosaki (Motohiro KOSAKI) to nagachika (Tomoyuki Chikanaga)
  • Target version deleted (2.1.0)
  • Parent task deleted (#5013)
#10

Updated by nagachika (Tomoyuki Chikanaga) over 7 years ago

  • Status changed from Assigned to Closed

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


merge revision(s) 39354,39356,39382: [Backport #5014]

* signal.c (sigsegv): avoid to use async signal unsafe functions
  when nested sigsegv is happen.
  [Bug #5014] [ruby-dev:44082]

* signal.c (check_stack_overflow): extract duplicated code and get rid
  of declaration-after-statement.  [Bug #5014]

* signal.c (ruby_abort): fix typo in r39354 [Bug #5014]
#11

Updated by nagachika (Tomoyuki Chikanaga) over 7 years ago

  • Project changed from Backport200 to Backport193
  • Status changed from Closed to Assigned
  • Assignee changed from nagachika (Tomoyuki Chikanaga) to usa (Usaku NAKAMURA)

チケット作成時期的に 1.9.3 にも必要かと考え移動します。

#12

Updated by usa (Usaku NAKAMURA) over 7 years ago

  • Status changed from Assigned to Closed

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


merge revision(s) 39354,39356,39382: [Backport #5014]

* signal.c (sigsegv): avoid to use async signal unsafe functions
  when nested sigsegv is happen.
  [Bug #5014] [ruby-dev:44082]

* signal.c (check_stack_overflow): extract duplicated code and get rid
  of declaration-after-statement.  [Bug #5014]

* signal.c (ruby_abort): fix typo in r39354 [Bug #5014]

Also available in: Atom PDF