* io.c (io_fillbuf): fix race between read and close, in the case
the IO gets closed before the reading thread achieve the lock.
[ruby-core:78845] [Bug #13076]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* vm_eval.c (yield_under): should evaluate the proc on the first
argument. [ruby-core:78839] [Bug #13074]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57194 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* regerror.c (onig_vsnprintf_with_pattern): use memcpy with the
known length instead of strcat.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57190 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* addr2line.c (follow_debuglink): insert global_debug_dir by using
memmove instead of copying to temporary buffer.
* dln.c (dln_load): use memcpy with the known length instead of
strcpy.
* gc.c (rb_gc_unprotect_logging): use strdup instead of malloc and
strcpy.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57189 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* win32/Makefile.sub (config.status): check configured target by
reading from config.status, and remove version dependent values
from config.h.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57188 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Fix unpacking with 'b', 'B', 'h' and 'H' format. Do not return an
uninitialized String to Ruby before filling the content bytes.
Fixes r11175 ("pack.c (pack_unpack): execute block if given with
unpacked value instead of creating an array", 2006-10-15).
[ruby-core:78841] [Bug #13075]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57187 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c (rb_str_enumerate_lines): in paragraph mode, do not
include newlines which separate paragraphs, so that it will be
consistent with IO#each_line.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57184 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* ext/-test-/memory_status/memory_status.c (read_status): use
TASK_BASIC_INFO instead of MACH_TASK_BASIC_INFO on old Mac OS.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57180 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* .gdbinit (rp): refine output of T_STRUCT and T_BIGNUM to show
all elements.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57176 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* regint.h (xvsnprintf): secure version functions are not
supported on old VC.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57175 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* hash.c (prime1, prime2): split long long literals for platforms
where LL suffix is not supported, e.g., VC6.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57174 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* compile.c (method_for_self): constify an argument of build
function for VC6.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57173 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c (usec2subsecx): fix return type, which is a numeric
object but not a long int. [ruby-dev:49912] [Bug #13066]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57172 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/lib/test/unit.rb (Test::Unit::RepeatOption): --repeat-count
option to repeat COUNT times while success.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57167 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/lib/test/unit/assertions.rb (prepare_syntax_check): extract
common preparation of arguments from assert_valid_syntax and
assert_syntax_error.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57159 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/lib/test/unit/assertions.rb (assert_valid_syntax): use
RubyVM::InstructionSequence.compile to get rid of executing the
code, instead of catch&throw. sample/trick2015/kinaba/entry.rb
no longer raises an Invalid return.
* test/lib/test/unit/assertions.rb (assert_syntax_error): ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* time.c (time_arg): dump sec and subsec arguments if subsecx is
insane.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57157 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test/-ext-/string/test_modify_expand.rb (test_integer_overflow):
no longer happens on platforms where size_t is larger than long,
e.g. 64bit windows, since r57122.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57156 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* string.c (rb_str_casecmp_p): [DOC] use Unicode escape form to
get rid of warning C4819 by Microsoft Visual C++.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
* test_float.rb: add test cases for Float#round with
half nil. Follow up r57130.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57151 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
As of Ruby 2.3, IO#close no longer raises IOError if the file is already
closed.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@57149 b2dd03c8-39d4-4d8f-98ff-823fe69b080e