[#68137] improve semantics of manpages — "Anthony J. Bentley" <anthony@...>
Hi,
1 message
2015/02/17
[#68144] Re: Future of test suites for Ruby — Anthony Crumley <anthony.crumley@...>
FYI...
4 messages
2015/02/17
[#68343] [Ruby trunk - Bug #10916] [Open] What the Ruby? SegFault? — ruby@...
Issue #10916 has been reported by why do i need this acct just to create a bug report.
5 messages
2015/02/27
[#68373] Re: [Ruby trunk - Bug #10916] [Open] What the Ruby? SegFault?
— "Martin J. Dürst" <duerst@...>
2015/03/02
> * Author: why do i need this acct just to create a bug report
[#68358] [Ruby trunk - Bug #10902] require("enumerator") scans LOAD_PATH 2x on every invocation — ruby@...1.net
Issue #10902 has been updated by Aman Gupta.
3 messages
2015/02/28
[ruby-core:68172] [Ruby trunk - Bug #10866] [Open] A signal handler in signal.c can corrupt the value of errno.
From:
sstewartgallus00@...
Date:
2015-02-18 17:46:37 UTC
List:
ruby-core #68172
Issue #10866 has been reported by Steven Stewart-Gallus.
----------------------------------------
Bug #10866: A signal handler in signal.c can corrupt the value of errno.
https://bugs.ruby-lang.org/issues/10866
* Author: Steven Stewart-Gallus
* Status: Open
* Priority: Normal
* Assignee:
* ruby -v: 2.2.0
* Backport: 2.0.0: UNKNOWN, 2.1: UNKNOWN, 2.2: UNKNOWN
----------------------------------------
A signal handler in signal.c can corrupt the value of errno. This is
common mistake. It should save and restore errno as in the following
patch. I think this is the only signal handler used but I am not that
familiar with the code.
Index: signal.c
===================================================================
--- signal.c (revision 49641)
+++ signal.c (working copy)
@@ -688,11 +688,15 @@
static RETSIGTYPE
sighandler(int sig)
{
+ int old_errnum = errno;
+
signal_enque(sig);
rb_thread_wakeup_timer_thread();
#if !defined(BSD_SIGNAL) && !defined(POSIX_SIGNAL)
ruby_signal(sig, sighandler);
#endif
+
+ errno = old_errnum;
}
int
--
https://bugs.ruby-lang.org/