aboutsummaryrefslogtreecommitdiffstats
path: root/process.c
Commit message (Collapse)AuthorAgeFilesLines
* * process.c (rb_proc_times): improve documentation.nagachika2011-05-141-4/+4
| | | | | | [ruby-core:35785] fixes #4581, reported by Andrew Grimm. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31564 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * re.c (Init_Regexp): Document option constants. Patch by Vincentdrbrain2011-05-121-0/+77
| | | | | | | | | | | | | | | | | | Batts. [Ruby 1.9 - Bug #4677] * lib/uri/common.rb (module URI): Documentation for URI. Patch by Vincent Batts. [Ruby 1.9- Bug #4677] * lib/uri/ftp.rb (module URI): ditto * lib/uri/generic.rb (module URI): ditto * lib/uri/http.rb (module URI): ditto * lib/uri/https.rb (module URI): ditto * lib/uri/ldap.rb (module URI): ditto * lib/uri/ldaps.rb (module URI): ditto * lib/uri/mailto.rb (module URI): ditto * process.c (Init_process): Document Process constants. Patch by Vincent Batts. [Ruby 1.9- Bug #4677] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31536 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_getmaxgroups, proc_setmaxgroups): Process#maxgroupskosaki2011-03-101-2/+10
| | | | | | | | | and Process#maxgroups= now raise NotImplementedError if the platform don't support supplementary groups concept. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31090 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (get_sc_ngroups_max): return -1 if platform don'tkosaki2011-03-101-1/+1
| | | | | | | | support NGROUPS_MAX. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31088 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_setgroups): cleanup.kosaki2011-03-081-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (get_sc_ngroups_max): fix indent.nobu2011-03-081-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31068 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (get_sc_ngroups_max): try to use NGROUPS_MAX at first ifkosaki2011-03-081-0/+2
| | | | | | | | _SC_NGROUP_MAX is not defined. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_setgroups): use getgrnam() if getgrnam_r() isnobu2011-03-081-3/+9
| | | | | | not available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31058 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c: RARRAY_LEN() returns long int.nobu2011-03-081-8/+12
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31057 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (get_sc_ngroups_max): define to wrap sysconf(3).naruse2011-03-071-2/+10
| | | | | | | | | | this also supports Windows which doesn't have sysconf(3). * process.c (maxgroups): use get_sc_ngroups_max. * process.c (proc_setmaxgroups): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (maxgroups): cast because sysconf(3)'s return value is long.naruse2011-03-071-3/+3
| | | | | | | | * process.c (proc_setmaxgroups): ditto. * process.c (proc_setgroups): cast because RARRAY_LEN() is long. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31053 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* small cleanup.kosaki2011-03-071-6/+6
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31049 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_setgroups): replace getgrnam() with getgrnam_r()kosaki2011-03-071-5/+16
| | | | | | | | because getgrnam() isn't thread safe. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31048 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_getmaxgroups, proc_setmaxgroups): refrectkosaki2011-03-071-6/+21
| | | | | | | | platform maxgroups limitation by default instead hardcoded 65536. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31047 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* cancel subversion backfire. sorrymatz2011-03-071-29/+51
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * gc.c (rb_gc_set_params): allow GC parameter configuration bymatz2011-03-071-51/+29
| | | | | | | environment variables. based on a patch from funny-falcon at https://gist.github.com/856296, but honors safe level. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31044 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c: NUM2RLIM is defined but no getrlimit and setrlimit onnobu2011-03-071-6/+6
| | | | | | mingw. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31042 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_getgroups): get rid of maxgroups dependency.kosaki2011-03-061-2/+6
| | | | | | | | ngroups can be calculated dynamically. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31037 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * configure.in: rlim_t use standard RUBY_REPLACE_TYPE mechanism.kosaki2011-03-061-11/+0
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31036 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_setmaxgroups): added negative value check.kosaki2011-03-061-1/+4
| | | | | | | | | This was suggested by Daniel Berger. Thanks Daniel! [ruby-core:35426][Bug#4467] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31035 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (maxgroups, proc_setmaxgroups): increase max groupskosaki2011-03-061-3/+24
| | | | | | | | limitation up to 65536. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31034 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (check_exec_redirect_fd, check_exec_redirect): raiseusa2011-03-031-6/+11
| | | | | | | | | | | ArgumentError if fd >= 3 on Windows because the feature is not supported. * test/ruby/test_process.rb (test_execopts_redirect): remove meaningless argument. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31017 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_run_exec_options_err): use MODET2NUM() instead LONG2NUM().kosaki2011-02-081-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30822 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_setgroups): add GC guard to prevent intermediatenagachika2011-02-071-1/+3
| | | | | | variable from GC. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30820 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * configure.in: Added mode_t type checking.kosaki2011-01-281-2/+2
| | | | | | | | | | | * process.c (rb_exec_arg_addopt): Use NUM2MODET() instead NUM2LONG because clang makes compile error by this narrowing conversion. * process.c (rb_run_exec_options_err): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30685 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (ALLOC_ARGV_WITH_STR): fix void pointer arithmetic.nobu2011-01-271-1/+1
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30663 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_exec_v, rb_proc_exec_n, rb_proc_exec)nobu2011-01-261-18/+43
| | | | | | | (proc_spawn_n, proc_spawn): get rid of too huge alloca(). [ruby-core:34827], [ruby-core:34833] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30662 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* update doc.akr2010-12-291-3/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30417 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (before_exec): add small comment.kosaki2010-12-261-0/+4
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30387 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c: parenthesize macro arguments.akr2010-12-231-9/+9
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@30329 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (p_uid_change_privilege, p_gid_change_privilege):nobu2010-11-051-6/+10
| | | | | | suppress warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29705 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_fork_err): save errinfo before fdopen.nobu2010-11-051-1/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29701 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_spawn_v): should spawn, not exec.nobu2010-11-051-1/+3
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29697 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_exec_v, proc_spawn_v): try to execute with sh ifnobu2010-11-041-7/+25
| | | | | | no shebang. [ruby-core:32745] [EXPERIMENTAL] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29695 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* update document.akr2010-09-121-0/+8
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29231 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rlimit_resource_name2int): support more limits:akr2010-09-111-12/+47
| | | | | | | | | | RLIMIT_MSGQUEUE, RLIMIT_NICE, RLIMIT_RTPRIO, RLIMIT_RTTIME and RLIMIT_SIGPENDING. (Init_process): ditto. patch by Run Paint Run Run. [ruby-core:32262] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29229 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rlimit_resource_name2int): use STRCASECMP to avoidakr2010-09-111-26/+42
| | | | | | | ALLOCA_N. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29226 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * ext/pty/pty.c (chfunc): pass through exceptions.nobu2010-09-021-7/+53
| | | | | | | | * io.c (rb_io_bufwrite, rb_io_bufread): added. * process.c (rb_fork_err): protect from exceptions. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@29171 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * class.c, compile.c, dir.c, file.c, iseq.c, parse.y, random.c:naruse2010-07-271-1/+1
| | | | | | | | clean unused-value warnings. * cont.c, process.c, vm_exec.h: clean cast warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28762 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_daemon): split from proc_daemon.nobu2010-07-131-8/+19
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28630 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_fork_err): suppress gcc 4.4 warnings.nobu2010-07-131-2/+4
| | | | | | | * random.c (fill_random_seed): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@28629 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_f_spawn): use correct command name for the errornobu2010-05-231-20/+35
| | | | | | | message. [ruby-dev:41395] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * array.c: Documentation: change => in call-seq to ->.marcandre2010-05-171-91/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Harmonize "#=>" in examples. [ruby-core:30206] * bignum.c: ditto * class.c: ditto * compar.c: ditto * cont.c: ditto * dir.c: ditto * encoding.c: ditto * enum.c: ditto * enumerator.c: ditto * error.c: ditto * eval.c: ditto * file.c: ditto * gc.c: ditto * io.c: ditto * load.c: ditto * marshal.c: ditto * math.c: ditto * numeric.c: ditto * object.c: ditto * pack.c: ditto * proc.c: ditto * process.c: ditto * random.c: ditto * range.c: ditto * re.c: ditto * ruby.c: ditto * signal.c: ditto * sprintf.c: ditto * string.c: ditto * struct.c: ditto * thread.c: ditto * time.c: ditto * transcode.c: ditto * variable.c: ditto * vm_eval.c: ditto * vm_method.c: ditto git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27865 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c: suppress warning for signed and unsigned typemame2010-05-171-6/+6
| | | | | | | | | | | | inconsistency. * ext/psych/parser.c: ditto. * ext/sdbm/_sdbm.c: ditto. * ext/syck/rubyext.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27864 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * eval.c (make_exception, rb_obj_extend): Fix error messages in case of wrongmarcandre2010-04-301-1/+1
| | | | | | | | | | | | | | | | | | | | | number of arguments * file.c (rb_f_test, rb_file_s_umask): ditto * numeric.c (int_chr, num_step): ditto * process.c (rb_f_sleep): ditto * re.c (rb_reg_initialize_m): ditto * signal.c (rb_f_kill, sig_trap): ditto * string.c (rb_str_aref_m, rb_str_aset_m, rb_str_count, rb_str_delete_bang, rb_str_slice_bang, rb_str_sub_bang, str_gsub): ditto * proc.c (curry): rdoc fix git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27558 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_f_fork): remove after_exec() which sometimes causedmame2010-04-231-3/+0
| | | | | | | | | | two timer threads started. [ruby-core:25217] * signal.c: use pthread_sigmask() instead of sigprocmask(). sigprocmask() is unspecified behavior on multi-thread programs. [ruby-core:25217] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27464 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (ruby_setsid): split from proc_setsid.nobu2010-04-011-7/+15
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_daemon): use EXIT_SUCCESS instead of magic number.nobu2010-04-011-2/+2
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27169 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (rb_f_exit_bang, rb_f_exit, rb_f_abort): fix rdoc.nobu2010-04-011-9/+12
| | | | git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27164 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* * process.c (proc_daemon): Process.daemon should raise an error onknu2010-03-301-4/+5
| | | | | | | | | failure regardless of whether the implementation uses daemon(3) or not. [ruby-dev:40832] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27106 b2dd03c8-39d4-4d8f-98ff-823fe69b080e