* test/-ext-/test_printf.rb (Test_SPrintf#test_{taint,untrust}): use
plain object so that the results of to_s and inspect are infected.
[ruby-dev:46053] [Bug #6881]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36712 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* sprintf.c (ruby__sfvextra): the result should be infected by the
given strings.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36707 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* sprintf.c (ruby__sfvwrite): set buffer length and exclude
uninitialized garbage to get correct coderange.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@36706 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
To avoid buffer overflow when smaller FD_SETSISE is used in ext
libraries.
* win32/win32.c (rb_w32_fdset): this function is not used anymore.
But we leave this for compatibility.
* win32/win32.c (rb_w32_select_with_thread): fix SEGV when smaller
FD_SETSISE is used in ext libraries. Dereference of fd_set pointer
causes SEGV.
* test/-ext-/win32/test_fd_setsize.rb(TestFdSetSize): add tests for
above.
* ext/-test-/win32/fd_setsize/depend: ditto.
* ext/-test-/win32/fd_setsize/extconf.rb: ditto.
* ext/-test-/win32/fd_setsize/fd_setsize.c: ditto.
[ruby-core:44588] [Bug #6352]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35595 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
the message in the given encoding. patched by now (Nikolai
Weibull) at [ruby-core:41160]. [Feature #5650]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35283 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/-test-/num2int/num2int.c (print_num2ll, print_num2ull): define
only if long long is available, and use long long printf modifier
checked by configure.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@35086 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
and st_delete_safe. patched by Sokolov Yura at
https://github.com/ruby/ruby/pull/84
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34963 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
check memory leak by invoking child ruby process and watch its
memory size.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@34520 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
constant of the path is not defined but defined on toplevel.
[ruby-core:41410] [Bug #5691]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33909 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
sigil of global, instance and class variable names should be
followed by non-numeric.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33426 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
raise_method_missing().
* vm_eval.c (send_internal): remove inadvertent symbol creation
from public_send. based on a patch by Jeremy Evans <code AT
jeremyevans.net> in [ruby-core:38576]. [Feature #5112]
* vm_insnhelper.c (vm_call_method): remove inadvertent symbol
creation from send and __send__, too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33419 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
select() with timeout may return early in old Linux kernels
with 250 Hz tickrate and no dynticks, so skip everything older
than 2.6.32 (which has long term support).
And, Make the timing assertions consistently use assert_operator with
timing difference in error message
Patch by Eric Wong. [Bug #5335] [ruby-core:39618]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33296 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
modification of rb_thread_fd_select().
based on a patch by Eric Wong. [Bug #5306] [ruby-core:39435]
* thread.c (rb_fd_rcopy): New. for reverse fd copy.
* test/-ext-/old_thread_select/test_old_thread_select.rb
(test_old_select_false_positive): test for bug5306.
* ext/-test-/old_thread_select/old_thread_select.c (fdset2array):
New. convert fdsets to array.
* ext/-test-/old_thread_select/old_thread_select.c (old_thread_select):
return 'read', 'write', 'except' argument of rb_thread_select()
to ruby script.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33256 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
(TestOldThreadSelect#test_old_select_read_timeout): if the machine
is fast enough, the time used by code around IO.select may be smaller
than Time implement threshold.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33131 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
typo.
* test/-ext-/old_thread_select/test_old_thread_select.rb
(TestOldThreadSelect#test_old_select_signal_safe): use SIGINT instead
of SIGUSR1 because the former is general and the latter is platform
dependent.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33130 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
rb_thread_fd_select(). old one is EINTR unsafe.
Patch by Eric Wong. [Bug #5229] [ruby-core:39102]
* test/-ext-/old_thread_select/test_old_thread_select.rb:
a testcase for rb_thread_select().
* ext/-test-/old_thread_select/old_thread_select.c: ditto.
* ext/-test-/old_thread_select/depend: ditto.
* ext/-test-/old_thread_select/extconf.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33117 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
[Bug #5153] [ruby-core:38736]
* io.c (argf_next_argv): remove the call of above function.
* ext/-test-/add_suffix, test/-ext-/test_add_suffix.rb: remove the test
extension module because this is only for testsing ruby_add_suffix().
* LEGAL: remove the mention about a part of util.c, because now we
removed the part.
* io.c (argf_next_argv): now the new filename is not guranteed to
use, so should check the return value of rename(2).
* test/ruby/test_argf.rb (TestArgf#test_inplace_rename_impossible):
now we expect same result with other platforms on no_safe_rename
platforms (=Windows).
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32826 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/-ext-/wait_for_single_fd/test_wait_for_single_fd.rb
(TestWaitForSingleFD#test_wait_for_closed_pipe): test for it.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31429 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
rb_wait_for_single_fd() internal function.
The patch was written by Eric Wong. [ruby-core:35991]
* test/-ext-/wait_for_single_fd/test_wait_for_single_fd.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@31428 b2dd03c8-39d4-4d8f-98ff-823fe69b080e