diff options
| author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-05-11 04:15:29 +0000 |
|---|---|---|
| committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2008-05-11 04:15:29 +0000 |
| commit | 142741b871da9e12e34de0250ba7e53441f92a3a (patch) | |
| tree | 27e677526f591c29820e9d781c0f3409069d7c48 /include/ruby | |
| parent | 12b769d538b13b92ad131193aa4e0381d716d062 (diff) | |
| download | ruby-142741b871da9e12e34de0250ba7e53441f92a3a.tar.gz ruby-142741b871da9e12e34de0250ba7e53441f92a3a.tar.xz ruby-142741b871da9e12e34de0250ba7e53441f92a3a.zip | |
* thread.c (thread_cleanup_func_before_exec): extracted from
thread_cleanup_func not to touch pthread data.
pthread_cond_destroy in forked process may cause deadlock on
Debian GNU/Linux Etch on x86, x86-64 and IA64.
this doesn't cause resource leak because the process will exec soon.
(terminate_atfork_before_exec_i): defined.
(rb_thread_atfork_before_exec): defined.
* include/ruby/intern.h (rb_thread_atfork_before_exec): declared.
* process.c (rb_exec_atfork): call rb_thread_atfork_before_exec
instead of rb_thread_atfork.
* io.c (popen_exec): call rb_thread_atfork_before_exec instead of
rb_thread_atfork.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@16355 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'include/ruby')
| -rw-r--r-- | include/ruby/intern.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/ruby/intern.h b/include/ruby/intern.h index 8f9b2940e..8b31576c5 100644 --- a/include/ruby/intern.h +++ b/include/ruby/intern.h @@ -308,6 +308,7 @@ VALUE rb_thread_main(void); VALUE rb_thread_local_aref(VALUE, ID); VALUE rb_thread_local_aset(VALUE, ID, VALUE); void rb_thread_atfork(void); +void rb_thread_atfork_before_exec(void); VALUE rb_exec_recursive(VALUE(*)(VALUE, VALUE, int),VALUE,VALUE); /* file.c */ VALUE rb_file_s_expand_path(int, VALUE *); |
